?

Log in

No account? Create an account
Client - LiveJournal Client Discussions [entries|archive|friends|userinfo]
LiveJournal Client Discussions

[ userinfo | livejournal userinfo ]
[ archive | journal archive ]

Client [Mar. 20th, 2002|06:57 pm]
LiveJournal Client Discussions

lj_clients

[bradfitz]
I wrote a little client because a fellow geek friend wanted it.
You run it from your shell, then it launches your $EDITOR.
It can post to multiple accounts on multiple servers / services.
So it could post to 2 LJ accounts, 1 DeadJournal account, and your Slashdot journal, all at once.
Potentially.
The Slash support is coming, but not from me. I just stubbed it for now.
Anyway:
http://www.bradfitz.com/programming/hacks/journal.pl.txt

Enjoy.

Oh, if you want current mood/music/security, just add below the Subject: line: (case doesn't matter)

Mood: whatever
Music: whatever
Security: friends or private
linkReply

Comments:
[User Picture]From: thegreatdark
2002-03-20 10:42 pm (UTC)

That gives me warm, fuzzy feelings

...or maybe that's just the burrito
(Reply) (Thread)
[User Picture]From: ai017
2002-04-09 09:43 am (UTC)
sorry for a dumb question and for writin to ya directly, but how
i'm supposed to recieve # of comments on my LJ entry? there are no such
entry in props.. =(

thank you
(Reply) (Thread)
From: hex
2006-04-24 11:10 pm (UTC)

Neat.

However, it craps out if your password has a space in it. I got around it by inserting this as line 98:
$params{$1} =~ s/_/ /g if $1 eq 'password';
Kind of a hack but after having changed my .journalconf appropriately I don't have to think about it again. Thanks for my new favorite client!
(Reply) (Thread)
From: hex
2006-04-24 11:37 pm (UTC)

Re: Neat.

Okay, I patched it up to do location and tags as well. Sorry for the codespam.
--- journal.pl	2006-04-25 00:33:32.000000000 +0100
+++ earlenal.pl	2006-04-25 00:36:24.000000000 +0100
@@ -42,10 +42,13 @@
 	'hour' => $now[2],
 	'min' => $now[1],
     };
-    foreach (qw(music mood)) {
+    foreach (qw(music mood location)) {
 	next unless $post->{$_};
 	$req->{"props"}->{"current_$_"} = $post->{$_};
     }
+    if ($post->{"tags"}) {
+        $req->{"props"}->{"taglist"} = $post->{"tags"};
+    }
     my $res = $xmlrpc->call('LJ.XMLRPC.postevent', $req);
     if ($res->fault) { 
 	print STDERR "Error posting to LJ server:\n".
@@ -91,7 +94,7 @@
     my %params;
     while (s/(\w+)=(?:([^\"\s]+)|(\"(.+?)\"))//) {
 	$params{$1} = $2 || $4;
-	
+	$params{$1} =~ s/_/ /g if $1 eq 'password'; # hack!
     }
     my $stype = $params{'servertype'};
     die "Unknown server type \"$stype\"\n"
(Reply) (Parent) (Thread)