[TWEAK] Better check if we're running KDE, in which case Spectacle should work
This commit is contained in:
11
README.md
11
README.md
@@ -3,9 +3,18 @@ Based on this: https://superuser.com/questions/1594667/how-can-i-make-a-screensh
|
|||||||
|
|
||||||
|
|
||||||
## Usage
|
## Usage
|
||||||
Copy the files in systemd to: `~/.config/systemd/user/`
|
Copy the files in systemd to: `~/.config/systemd/user/`:
|
||||||
|
```bash
|
||||||
|
cp systemd/* ~/.config/systemd/user/
|
||||||
|
```
|
||||||
|
|
||||||
Modify the paths in them so they point to wherever this repo is.
|
Modify the paths in them so they point to wherever this repo is.
|
||||||
|
```bash
|
||||||
|
nano ~/.config/systemd/user/screenshot.service
|
||||||
|
```
|
||||||
|
|
||||||
Run:
|
Run:
|
||||||
```bash
|
```bash
|
||||||
|
systemctl --user enable screenshot.service screenshot.timer
|
||||||
systemctl --user start screenshot.service screenshot.timer
|
systemctl --user start screenshot.service screenshot.timer
|
||||||
```
|
```
|
||||||
@@ -13,7 +13,7 @@ SCR_NEW="$DIR/$DAY/$TIME.$FORMAT"
|
|||||||
SCR_LAST=`ls -t $DIR/$DAY/*.png | head -n1`
|
SCR_LAST=`ls -t $DIR/$DAY/*.png | head -n1`
|
||||||
|
|
||||||
# do a screenshot
|
# do a screenshot
|
||||||
if [ "$DESKTOP_SESSION" = "plasmawayland" ]
|
if [ "$XDG_CURRENT_DESKTOP" = "KDE" ]
|
||||||
then
|
then
|
||||||
spectacle -bn -o $SCR_NEW
|
spectacle -bn -o $SCR_NEW
|
||||||
else
|
else
|
||||||
|
|||||||
Reference in New Issue
Block a user