Here's a nice photo of my suburb with some rain clouds approaching.
When I have 90% common files on my laptop and desktop, and I want to sync the remaining files without accidentally deleting anything, I run these commands:
$ rsync -pogz -urave ssh ~/localdir remote.computer:~/
$ rsync -pogz -urave ssh remote.computer:~/localdir ~/
Then, as you are sure you are now up-to-date on both machines, you can start deleting files on one, and then sync those deletions to the other with:
$ rsync --delete -pogz -urave ssh ~/localdir remote.computer:~/
Note:
rsync doesn't seem very good at moved files. It will try to copy the whole file across again if it has moved into another dir... check out the fuzzy option... and also this thread for further info.
If you have a *nix box, you can set the timezone of the box by making /etc/localtime a symlink to the appropriate /usr/share/zoneinfo/ file.
But what if different people on your box have different timezones? Each user can manually set his own timezone simply by doing this:
$ export TZ=Australia/Hobart
... why not put that in your .bashrc?
Just by using the utf8 pragma in your Perl, you can do things like this:
use Modern::Perl;
use utf8;
my $天 = 'sky!';
say $天;
for my $否 (split(/ /, "no no NO no! NO!")) {
say $否;
}
Some problems are so complex that you have to be highly intelligent and well informed just to be undecided about them.
Seeing escape codes when you run perldoc?
Set your $PAGER environment variable up correctly:
export PAGER="less -R"
vared:
zsh% blah="some very long thing here"
zsh% echo $blah
some very long thing here
zsh% vared blah
some very long thing here oh here is my edit
zsh% echo $blah
some very long thing here oh here is my edit
.. when you do a vared variablename, it will print the current value of the variable and puts the cursor at the end, waiting for you to edit the line. So if you need to edit your PATH, and want to add something new to the end - or change the last directory, vared makes it easy.
The magic-equals:
bash$ ls `which perl`
/opt/local/bin/perl
zsh% ls =perl
/opt/local/bin/perl
The double-star:
zsh% ls proj/bin/tools/mysql_fix.pl # `mysql_fix.pl' is in our tree
proj/bin/tools/mysql_fix.pl
zsh% head -1 **/mysql_fix.pl # double-star knows where to find it!
#!/usr/bin/env perl
... between two Perlers today:
chromatic:
Some days the jerks and bugs and workarounds and fame-chasing pundits make me want to leave technology as a profession.
Larry Wall:
If you do leave, you will find jerks and bugs and workarounds and fame-chasing pundits in most other professions too.
chromatic
At least real life hides its backwards compatibility misfeatures in DNA where I can't get at it.
Haha :-)
Django Python 960.gs Git Vim NetBSD Nginx
The author is a software engineer living in Australia. He sux at guitar, loves camping, doesn't like cake, does like coffee and is a lazy home brewer.
Help
Latest entries
*BSD Agile Apache Apple Athletics Beer Best-Practice Censorship Comedy Cool Crosswords Deployment Django English Exim Firefox Git Hardcore Health Interface irssi Javascript Jira Languages Linux Makefile Markdown Mathematics Mobile Broadband MySQL NetBSD nginx Nokia OSX Perl Photo Privacy Python Rant Requirements rsync Ruby Shell Slackware SQL SQLite SSH Standards Subversion Testing ThisBlog Vim VMWare (Fusion) VPN WDTEM X Yum zsh
Perldoc Output
Yum
Possum
Git's Index
Jira Project Keys
The Coffee Shop
Git GUI
It is more important...
Questioning Unix (and Other) File Times
The Frog King Photo
Rain Cloud Photo
rsync
Timezone
utf8 in your Perl
Theatre Ceiling Photo
Some problems are so complex...
Colours in your PAGER
zsh vared
zsh magic-equals and double-star
Funny Tweets
ChoppingBoard, Project365, RageQuit