Kitaab

: linux

dev

published 1970-01-01 00:00

updated 1970-01-01 00:00

linux tips and tricks

nixOS

installing an app to the gnome menu

add an desktop entry to ~/.local/share/applications/ for desktop entries available to a single user (look in that folder for examples)

cron

crontab -e to edit the cron file cron takes 5 inputs followed by the CMD you wish to run:

          • ls min hour day month week

the above cron tag will run ls every minute of every day all the time. Hour is in 24hr format. So 00 00 * ~/scripts/music-pull will run music-pull everyday at 12AM

its generally advisable to schedule these scripts at specific odd times so that they don't clash with other things

There are also other types of formats: @reboot (i've run into trouble with this, as it is only called specifically when the computer is rebooted, not at any boot)

ssh copy

to copy your ssh key to a new computer run ssh-copy-id user@server

ssh config

the ssh config file is truly versatile

hamachi

stop: /etc/init.d/logmein-hamachi stop start: /etc/init.d/logmein-hamachi start

git

rename a branch:

  • git branch -m

pull upstream master changes:

see remote repos:

  • git remote -v

add remote repo:

  • git remote add ssh://:<dir/of/remote>
  • git remote add https://<web.repo.com>:<dir/to/remote>

create a git branch:

  • git branch

checkout a branch:

  • git checkout

push to specific branch:

  • git push --set-upstream

systemd

theming


Backlinks