Posts by stas
Keep your ssh session alive
(original posted: 2012)
To keep your ssh session alive thus preventing to being locked out when the firewall is reloaded or whatever add a ‘config’ file to you local .ssh directory.
$ cat .ssh/config
Host *
ServerAliveInterval 60
Now your session is will be kept alive.”
git ssh Agent admitted failure to sign using the key
hen you get a “”Agent admitted failure to sign using the key”” when trying to git pull or push you can add your key to ssh.
ssh-add ~/.ssh/id_rsa
Encode url from bash
(original posted: 2012)
IF you need to encode parts of a POST url:
SUM=$(md5sum $APPNAME.tar.gz.gpg 1> /dev/null)
SUMENC=$(echo $SUM’ /*$$[]’ | perl -MURI::Escape -lne ‘print uri_escape($_)’)”
kv language designing with anchorlayout
0(original posted: 2012)
When designing a Kivy menu with the kv language I run into troubles with the anchorlayout object.
It seems that you need to put every object inside a achorlayout which itself is part of a anchorlayout.
Sounds a bit vague so an example should do:
AnchorLayout: id: topmenu anchor_x: 'center' anchor_y: 'top' BoxLayout: orientation: 'horizontal' AnchorLayout: anchor_x: 'left' anchor_y: 'top' padding: 8 Button: id: infobutton size: (48, 48) size_hint: None, None background_normal: 'info_button.png' background_down: 'info_button.png' on_press: root.on_button_clicked("info") AnchorLayout: anchor_x: 'center' anchor_y: 'top' padding: 8 BoxLayout: padding: 0 spacing: 4 size: (300, 48) size_hint: None, None orientation: 'horizontal' AnchorLayout: anchor_x: 'center' anchor_y: 'top' Button: size: (48, 48) size_hint: None, None background_normal: 'star1.png' on_press: root.on_button_clicked("star1") AnchorLayout: anchor_x: 'center' anchor_y: 'top' Button: size: (48, 48) size_hint: None, None background_normal: 'star1.png' on_press: root.on_button_clicked("star2") AnchorLayout: anchor_x: 'right' anchor_y: 'top' padding: 8 Button: id: quitbutton size: (48, 48) size_hint: None, None background_normal: 'quit_button.png' background_down: 'quit_button_ro.png' on_press: root.on_quit_button_clicked()