Skip to content

Commit

Permalink
Adapt s2ram to Ubuntu
Browse files Browse the repository at this point in the history
  • Loading branch information
mpapis committed Apr 26, 2017
1 parent b49d588 commit 77b408c
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 1 deletion.
1 change: 0 additions & 1 deletion .alias
Original file line number Diff line number Diff line change
Expand Up @@ -13,5 +13,4 @@ alias grm="git checkout master && git pull && git checkout - && git rebase maste
alias open=xdg-open
alias jb="JRUBY_OPTS=--dev bundle"
alias router="ssh -fY papis-router.local xfce4-terminal"
alias s2ram="(/usr/lib64/libexec/kscreenlocker_greet &) ; sleep 0.5 ; sudo /usr/lib/systemd/systemd-sleep suspend"
alias zdup="sudo zypper dup --auto-agree-with-licenses --allow-vendor-change --allow-downgrade --allow-name-change"
17 changes: 17 additions & 0 deletions .functions
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,23 @@ ml()
shift
done | column -s"#" -t
}

s2ram()
{
sudo true
(
if [[ -f /usr/lib/x86_64-linux-gnu/libexec/kscreenlocker_greet ]]
then /usr/lib/x86_64-linux-gnu/libexec/kscreenlocker_greet &
else /usr/lib64/libexec/kscreenlocker_greet &
fi
)
sleep 0.5
if [[ -f /lib/systemd/systemd-sleep ]]
then sudo /lib/systemd/systemd-sleep suspend
else sudo /usr/lib/systemd/systemd-sleep suspend
fi
}

gri()
{
git rebase --interactive "$@"
Expand Down

0 comments on commit 77b408c

Please sign in to comment.