]> www.wagner.pp.ru Git - oss/vjournal.git/commitdiff
stubs for scripts
authorVictor Wagner <wagner@atlas-card.ru>
Wed, 9 Oct 2013 14:05:51 +0000 (18:05 +0400)
committerVictor Wagner <wagner@atlas-card.ru>
Wed, 9 Oct 2013 14:05:51 +0000 (18:05 +0400)
Makefile.PL
bin/comment [new file with mode: 0644]
bin/login [new file with mode: 0644]
bin/post [new file with mode: 0644]
bin/userinfo [new file with mode: 0644]

index 4cebc97af6ff1ba0d9d07916e2c50c81383bd22f..ee7782339d436a885d755177829305c6de9d295c 100644 (file)
@@ -3,7 +3,7 @@
 use ExtUtils::MakeMaker;
 
 WriteMakefile(
-       NAME=>'MicroBlog',
+       NAME=>'VJournal',
        VERSION=>0.1
 );
 
diff --git a/bin/comment b/bin/comment
new file mode 100644 (file)
index 0000000..3edef13
--- /dev/null
@@ -0,0 +1,19 @@
+#!/usr/bin/perl -T
+
+=head1 NAME
+
+vjcomment - post comments on blog entries
+
+=head1 SYNOPSIS
+
+       http://your.server.com/cgi-bin/vjcomment/your-blog-top/2013/11/30-pst.html?id=cmt12
+
+=head1 DESCRIPTION
+
+This script processes a comment, posted from the form in the HTML
+file and, if auth OK, inserts comment into this html file.
+
+If comment is answer to another comment id of parent comment should be
+passed. If no id is passed, comment is assumed top-level.
+
+=cut
diff --git a/bin/login b/bin/login
new file mode 100644 (file)
index 0000000..fffadaa
--- /dev/null
+++ b/bin/login
@@ -0,0 +1,16 @@
+#!/usr/bin/perl -T
+
+=head1 NAME
+
+vjlogin - authenticate openid users
+
+=head1 SYNOPSIS
+
+       http://your.server.com/cgi-bin/vjlogin/your-blog-top
+
+=head1 DESCRIPTION
+
+Authenticates user with external OpenID provider, creates VJournal
+session and sets approprieate cookie.
+
+=cut
diff --git a/bin/post b/bin/post
new file mode 100644 (file)
index 0000000..1435e91
--- /dev/null
+++ b/bin/post
@@ -0,0 +1,24 @@
+#!/usr/bin/perl -T
+
+=head1 NAME
+
+vjpost - submit or edit blog posts
+
+=head1 SYNOPSIS
+
+       http://your.server.org/cgi-bin/vjpost/your-blog-top
+
+For submit post or set up blog
+
+    http://your.server.org/cgi-bin/vjpost/your-blog-top/2013/12/11-my-post.html
+
+For editing post visible as:
+
+       http://your.server.org/yoru-blog-top/2013/12/11-mypost.html
+
+=head1 DESCRIPTION
+
+B<vjpost> is blog owner interface to VJournal system. It allows to
+create new posts, edit existing posts or perform initial blog setup
+
+=cut
diff --git a/bin/userinfo b/bin/userinfo
new file mode 100644 (file)
index 0000000..0d92d69
--- /dev/null
@@ -0,0 +1,34 @@
+#!/usr/bin/perl -T
+
+=head1 NAME
+
+vjuserinfo - return current user info as json
+
+=head1 SYNOPSIS
+
+       http://your.server.org/cgi-bin/vjuserinfo/your-blog-top
+
+=head1 DESCRIPTION
+
+Returns info about current user using following format
+       
+       { 
+               url:"somebody.livejournal.com",
+               displayname:"somebody@lj",
+               state: "guest",
+               avatar: {src: "http://your.server.org/avatars/somebody@lj.gif",
+               width:100, height:100},
+       }
+
+B<state> can be B<owner>, B<guest> or B<banned>.
+
+If user is not logged in, returns following structure:
+
+    {
+               state: "notlogged",
+               providers: [
+                       {name: "Live journal",icon:"/avatars/lj.gif",format: "%s.livejournal.com"}
+           ...
+       }
+
+=cut