GIT – Rename a git branch
… its so easy for the current branch:
1 |
$> git branch -m <newname> |
… and for any branch too:
1 |
$> git branch -m <oldname> <newname> |
… its so easy for the current branch:
1 |
$> git branch -m <newname> |
… and for any branch too:
1 |
$> git branch -m <oldname> <newname> |
If you got the “Too many authentication failures for X” error on trying to connect to a server over ssh you can use the -o parameter to set the PubkeyAuthentication option to no.
1 |
ssh -o PubkeyAuthentication=no root@host |
With that parameter your machine won’t try to send all your public keys any more on ssh connect. As an alternative […]
As a reverse function of nl2br you can use:
1 2 3 4 5 6 7 8 9 10 11 |
<?php /** * reverse function for nl2br * @param $string - string with br's * @return string - string with \n */ function br2nl($string) { return preg_replace('/\<br(\s*)?\/?\>/i', "\n", $string); } ?> |
To generate the headline styles for H1 – H6 you can use a loop:
1 2 3 4 5 |
@for $i from 1 through 6 { h#{$i} { font-size: 2.5em - (0.2em * $i); } } |