Compare commits
13 Commits
Author | SHA1 | Date |
---|---|---|
Марков Сергей Викторович | 250ef48928 | 2 years ago |
Sergey Markov | c1241e72b0 | 2 years ago |
Sergey Markov | a7e699e3ec | 2 years ago |
Sergey Markov | f935c6404e | 2 years ago |
markow | 2b7de57272 | 2 years ago |
markow | b72bcd867e | 2 years ago |
markow | 263a8c8d06 | 2 years ago |
markow | db89c20e99 | 2 years ago |
Sergey-V Markov | 5492e1be17 | 2 years ago |
Sergey-V Markov | 308f706632 | 2 years ago |
Sergey-V Markov | dfa29fcfc4 | 2 years ago |
Sergey-V Markov | 0919a135b2 | 2 years ago |
Sergey-V Markov | 52b110f219 | 2 years ago |
11 changed files with 283 additions and 45 deletions
@ -1,13 +1,59 @@
|
||||
# Basealt web-greeter-theme |
||||
The lightdm web-greeter theme for altlinux OSes |
||||
![](https://git.markow.su/markow/git-utils/raw/branch/master/screenshots/web-greeter-theme-basealt-1.png) |
||||
The lightdm web-greeter theme for altlinux OSes<br/> |
||||
![](https://git.markow.su/markow/git-utils/raw/branch/master/screenshots/web-greeter-theme-basealt.gif) |
||||
|
||||
# Install |
||||
``` |
||||
# apt-repo add rpm http://packages.markow.su/altlinux p10/branch/x86_64 classic |
||||
# apt-repo add rpm http://packages.markow.su/altlinux p10/branch/noarch classic |
||||
|
||||
# apt-get update |
||||
# apt-get install web-greeter-theme-basealt |
||||
``` |
||||
|
||||
# Configure |
||||
## Set web-greeter as greeter-session for lightdm |
||||
``` |
||||
# pluma /etc/lightdm/lightdm.conf |
||||
``` |
||||
Set greeter-session to web-greeter |
||||
|
||||
## Set basealt theme |
||||
``` |
||||
# pluma /etc/lightdm/web-greeter.yml |
||||
``` |
||||
Change "theme" config to basealt |
||||
|
||||
## Set user logo for theme |
||||
``` |
||||
# mkdir -p /var/lib/lightdm-data/$USER |
||||
# cp <your logo file>.png /var/lib/lightdm-data/$USER/face.png |
||||
``` |
||||
|
||||
# Packaging |
||||
To pack own rpm pckage: |
||||
``` |
||||
# apt-get update |
||||
# apt-get install hasher gear |
||||
|
||||
$ git clone https://git.markow.su/markow/web-greeter-theme-basealt.git |
||||
$ cd web-greeter-theme-basealt |
||||
|
||||
$ mkdir ~/.hasher |
||||
$ hsh --initroot ~/.hasher |
||||
$ gear-hsh -v ~/.hasher --target=noarch --no-sisyphus-check |
||||
``` |
||||
To use your own rpm: |
||||
1. point your apt to your local hasher repo |
||||
2. do apt-get update |
||||
3. do apt-get install web-greeter-theme-basealt |
||||
|
||||
# Features |
||||
* Select a user |
||||
* Select a session |
||||
* Select a wallpapper |
||||
* Store settings |
||||
* User logo ca be shown if it is set in greeter for the user |
||||
* User logo can be shown if it is set in greeter for the user |
||||
|
||||
|
||||
|
||||
|
@ -0,0 +1,2 @@
|
||||
primary_html: "index.html" |
||||
secondary_html: "secondary.html" |
@ -0,0 +1,20 @@
|
||||
<!DOCTYPE html> |
||||
<html lang="en"> |
||||
<head> |
||||
<meta charset="UTF-8"> |
||||
<link rel="stylesheet" href="style.css" class="style"> |
||||
<script type="text/javascript" src="wallpapper.js"></script> |
||||
<script type="text/javascript"> |
||||
function initGreeter() { |
||||
let defaultWallpapper = window.localStorage.getItem(DEFAULT_WALLPAPPER); |
||||
if(defaultWallpapper) { |
||||
updateWallpapper(defaultWallpapper); |
||||
} |
||||
} |
||||
|
||||
window.addEventListener("GreeterReady", initGreeter) |
||||
</script> |
||||
<title>Example Theme</title> |
||||
</head> |
||||
<body /> |
||||
</html> |
@ -0,0 +1,30 @@
|
||||
const DEFAULT_WALLPAPPER = "defaultWallpapper"; |
||||
const WALLPAPPER_ELEMENT = "wallpappers"; |
||||
|
||||
|
||||
function setWallpapper(wallpapper) { |
||||
console.log(wallpapper) |
||||
var body = document.getElementsByTagName('body')[0]; |
||||
body.style.backgroundImage = wallpapper; |
||||
} |
||||
|
||||
function updateWallpapper(wallpapper) { |
||||
let wall_file = `url(wallpappers/${wallpapper})` |
||||
if (wallpapper === 'User') { |
||||
setWallpapper(`url(wallpappers/Rosatomflot.jpg)`) |
||||
theme_utils.dirlist(`/usr/share/web-greeter/themes/basealt/wallpappers`, true, (images) => { |
||||
if(images) { |
||||
console.log(images) |
||||
for (let i = 0; i < images.length; i++) { |
||||
let image = images[i] |
||||
if(image.indexOf("/wallpapper.png") == image.length - 15) { |
||||
setWallpapper(`url(${image})`) |
||||
console.log(wall_file) |
||||
} |
||||
} |
||||
} |
||||
}); |
||||
} else { |
||||
setWallpapper(`url(wallpappers/${wallpapper})`) |
||||
} |
||||
} |
Before Width: | Height: | Size: 275 KiB After Width: | Height: | Size: 1.6 MiB |
@ -0,0 +1,53 @@
|
||||
%define shortname basealt |
||||
|
||||
Name: web-greeter-theme-basealt |
||||
Version: 1.0.5 |
||||
Release: alt1 |
||||
|
||||
Summary: A theme for web-greeter on AltLinux |
||||
License: MIT |
||||
Group: System/Configuration/Boot and Init |
||||
|
||||
Url: https://git.markow.su/markow/web-greeter-theme-basealt |
||||
Source: %name-%version.tar |
||||
|
||||
Packager: Sergey-V Markov <markow@altlinux.org> |
||||
|
||||
Requires: lightdm lightdm-webkit2-greeter |
||||
|
||||
BuildRequires:rsync |
||||
|
||||
%description |
||||
A theme for web-greeter on AltLinux, it has Russian pretty interface with Basealt logos and so on |
||||
|
||||
%prep |
||||
%setup |
||||
|
||||
%build |
||||
|
||||
%install |
||||
|
||||
mkdir -p %buildroot%_datadir/web-greeter/themes/%shortname |
||||
rsync -rv --exclude-from=./.copyignore ./* %buildroot%_datadir/web-greeter/themes/%shortname/ |
||||
|
||||
%files |
||||
%_datadir/web-greeter/themes/%shortname/* |
||||
|
||||
%changelog |
||||
* Mon Apr 3 2023 Sergey-V Markov <markow@altlinux.org> 1.0.5-alt1 |
||||
- Allow to set user wallpapper |
||||
|
||||
* Sun Jan 8 2023 Sergey-V Markov <sergey@markow.su> 1.0.4-alt1 |
||||
- Bug fix with defaults updating storage |
||||
|
||||
* Tue Oct 25 2022 Sergey-V Markov <sergey@markow.su> 1.0.3-alt1 |
||||
- New feature to wait authentication |
||||
|
||||
* Sat Oct 22 2022 Sergey-V Markov <sergey@markow.su> 1.0.2-alt3 |
||||
- Add shortname usage |
||||
|
||||
* Sat Oct 22 2022 Sergey-V Markov <sergey@markow.su> 1.0.2-alt2 |
||||
- Do not copy garbage files |
||||
|
||||
* Fri Oct 21 2022 Sergey-V Markov <sergey@markow.su> 1.0.2-alt1 |
||||
- New theme |
Loading…
Reference in new issue