1
0
Fork 0
Commit graph

125 commits

Author SHA1 Message Date
Andy Wingo
7a1944b240 per-tag feed links
* tekuti/page.scm (page-show-tag): Add a feed link here.
2011-04-26 15:39:06 +02:00
Andy Wingo
62a351d8d5 optimization for with=foo
* tekuti/page.scm (page-feed-atom): Reduce "with=unknown" to nothing.
2011-04-26 15:12:05 +02:00
Andy Wingo
cee672f117 multiple with query args add tags to the set
* tekuti/page.scm (page-feed-atom): Reimplement more clearly, and give
  "with" inclusionary meaning.
2011-04-25 20:30:57 +02:00
Andy Wingo
08e1e58f1f add ?with=guile&without=gnu
* tekuti/page.scm (page-feed-atom): Reimplement Brian's thing with
  "with" and "without" query args, to allow for multiple tags to be
  included or excluded.

* tekuti/request.scm (request-query-ref-all): New helper.
2011-04-25 20:06:11 +02:00
Andy Wingo
26216a593a with-i/o procedures close their ports
* tekuti/util.scm (with-output-to-string*, with-input-from-string*): New
  hacky helpers, which close the port before returning the string or
  result.  Hopefully reduce pressure on the GC.
  (shell:quote):
* tekuti/git.scm (git-commit-reverse-operations, with-output-to-blob*)
  (with-input-from-blob*):
* tekuti/filters.scm (wordpress->sxml): Use the string* procedures.
2011-04-25 19:10:07 +02:00
Brian Gough
a4bad7a561 add atom feeds for tags 2011-04-25 19:05:49 +02:00
Andy Wingo
efc25df8f4 don't bother allocating iconv info on pipe
* tekuti/git.scm (run): Don't set encoding on pipe, as we just use
  bytevector io anyway.
2011-02-22 23:52:11 +01:00
Andy Wingo
a05d9a5df8 use ice-9 binary-ports
* tekuti/git.scm:
* tekuti/request.scm: Use ice-9 binary-ports instead of (rnrs io
  ports).
2011-02-22 22:21:30 +01:00
Andy Wingo
1636c96f9f remove obsolete (tekuti url)
* tekuti/url.scm: Remove.
* Makefile.am: Remove url.scm

* tekuti/post.scm: Remove reference to (tekuti url).
  (parse-post-data): Use uri-encode.
2011-02-22 22:19:30 +01:00
Aleix Conchillo Flaque
800e7d9a05 do not remove numbers and s/./-/ in post keys 2011-02-18 23:36:10 +01:00
Andy Wingo
fce14fbddf s/unparse-uri/uri->string/ 2011-02-18 23:34:57 +01:00
Aleix Conchillo Flaque
2a87435f81 fixes due to (web http) updates 2011-02-18 23:34:27 +01:00
Andy Wingo
a357b2a0dc support for deleting post comments 2011-02-18 23:34:17 +01:00
Andy Wingo
9ec70ebff5 add support for deleting posts 2011-02-18 23:31:42 +01:00
Aleix Conchillo Flaque
66e04753f6 wordpress-xmlrpc: added usage help 2011-02-18 23:28:46 +01:00
Aleix Conchillo Flaque
cffa7dea90 wordpress-xmlrpc: more youtube/googlevideo updates 2011-02-18 23:27:50 +01:00
Aleix Conchillo Flaque
612577eca9 inform the user of malformed xhtml internal error when publishing 2011-02-18 23:27:45 +01:00
Aleix Conchillo Flaque
0dee43b2a0 wordpress-xmlrpc: use video.google.com instead of .es 2011-02-18 23:26:18 +01:00
Aleix Conchillo Flaque
199ad57615 wordpress-xmlrpc: fix googlevideo and youtube urls 2011-02-18 23:26:13 +01:00
Aleix Conchillo Flaque
606ecad873 wordpress-xmlrpc: fix media html tags (again) 2011-02-18 23:26:09 +01:00
Aleix Conchillo Flaque
2da5248073 wordpress-xmlrpc: fix media html tags 2011-02-18 23:26:05 +01:00
Aleix Conchillo Flaque
280696ea06 wordpress-xmlrpc: added support for wp media tags youtube/googlevideo 2011-02-18 23:25:59 +01:00
Aleix Conchillo Flaque
736a074097 wordpress-xmlrpc: download unlimited comments 2011-02-18 23:25:43 +01:00
Aleix Conchillo Flaque
fc07af26f6 wordpress-xmlrpc: use str type for pycurl urls 2011-02-18 23:23:06 +01:00
Aleix Conchillo Flaque
93789f0d07 add head link tag for atom feed 2011-02-18 23:22:46 +01:00
Aleix Conchillo Flaque
bf90b687e0 added wordpress (xmlprc) to tekuti script 2011-02-18 23:22:11 +01:00
Andy Wingo
f350e252fc mod-lisp updates
* tekuti/mod-lisp.scm: update tekuti/mod-lisp to parse headers to
  symbols, and to deal in bytevectors only.
2011-02-18 23:20:26 +01:00
Andy Wingo
bed9fff79d request-form-data smarter about character encodings
* tekuti/request.scm (request-form-data): Allow the body to be a
  bytevector. Update to new uri interface, and allow alternate
  encodings.
2010-12-11 19:18:13 +01:00
Andy Wingo
98cac18528 mod-lisp calls setvbuf only once
* tekuti/mod-lisp.scm (mod-lisp-read): Like the http impl, just setvbuf
  once, and don't throw away data (!).
2010-12-06 20:01:43 +01:00
Andy Wingo
68966d9e17 fix time comparisons
* tekuti/cache.scm (make-entry): Fix time comparisons.
2010-12-06 13:06:50 +01:00
Andy Wingo
8f2e3b741c more etag
* tekuti/page.scm (page-feed-atom): Also set etag on 304 responses
  here.
2010-12-06 13:04:24 +01:00
Andy Wingo
839d2e27eb cache returns 304 as appropriate; more pages set etags
* tekuti/cache.scm (update-cache): Expand cache size back to 20.
  (cached-response-and-body, make-entry): Entries are now procedures
  that return the cached pair. They also have some more smarts regarding
  etags, last-modified, and conditional requests.

* tekuti/page-helpers.scm (respond): Add etag arg. Set a date.

* tekuti/page.scm: Set etags on a number of pages.
2010-12-06 13:00:53 +01:00
Andy Wingo
15f024a12d robustness in mod-lisp-read
* tekuti/mod-lisp.scm (mod-lisp-read): Close the port if there is an
  error reading the request.
2010-12-06 11:37:47 +01:00
Andy Wingo
fc386dcb71 fix caching
* tekuti/cache.scm: Update with more structure. Use take-max, not
  list-head. Only cache cacheable request-response pairs.

* tekuti/index.scm: Add cache as index entry. Also return the index ref
  within the index itself, instead of at the head.

* tekuti/web.scm: Don't pass cache around, it's part of the index
  now. Adapt to new API.
2010-12-05 20:23:01 +01:00
Andy Wingo
aa86b62d79 simpler caching algorithm
* tekuti/cache.scm: Simpler LRU algorithm for the cache. Conses more,
  but throws away the cache less.
2010-12-04 20:08:16 +01:00
Andy Wingo
bc53abe0b6 mod-lisp sets client sockets to iso-8859-1
* tekuti/mod-lisp.scm (read-request/mod-lisp): Set port's encoding to
  latin-1, so that we reading one char reads one byte.
2010-12-04 13:15:47 +01:00
Andy Wingo
83a569885a use the simple cache
* tekuti/web.scm: Use the cache.
2010-12-03 19:59:45 +01:00
Andy Wingo
c099b9532c add a simple cache
* tekuti/cache.scm: Add a simple cache.
2010-12-03 19:59:32 +01:00
Andy Wingo
55617ccff2 tekuti git uses get-bytevector-all
* tekuti/git.scm (run): Use get-bytevector-all instead of
  read-delimited.
2010-12-03 19:59:15 +01:00
Andy Wingo
5900823c3e update mod-lisp web server impl
* tekuti/mod-lisp.scm: Update to use the poll set, do the right thing
  for SIGPIPE, etc, following http.scm. Maybe now it will actually be
  reliable.
2010-12-03 17:00:10 +01:00
Andy Wingo
a8ad41b06d src/tekuti is a shell script
* src/tekuti: Change to be a shell script.
2010-11-24 21:37:27 +01:00
Andy Wingo
507db16d48 fix locale setting
* src/tekuti: Use sh, not bash.

* tekuti/boot.scm (boot): Doh, actually set the locale.
2010-11-23 23:15:54 +01:00
Andy Wingo
16434bdf1d fix command-line parsing bugs
* src/tekuti: Fix bug processing command-line args.
2010-11-23 23:00:39 +01:00
Andy Wingo
6df26e1c72 fix mod-lisp bugs
* tekuti/mod-lisp.scm (url, read-request/mod-lisp)a
  (write-headers/mod-lisp, write-response/mod-lisp): Fix a number of
  mod-lisp bugs.
2010-11-23 21:48:43 +01:00
Andy Wingo
c2d3231e24 fix post content-type check
* tekuti/request.scm (request-form-data): Fix content-type check.
2010-11-22 23:50:48 +01:00
Andy Wingo
473bd070ae don't display doctype if unnecessary
* tekuti/page-helpers.scm (respond): Don't display a doctype if we
  aren't given one.
2010-11-22 23:42:10 +01:00
Andy Wingo
dda89fe5bf config refactor so that tekuti knows its public address
* tekuti/config.scm (*public-host*, *public-port*)
  (*private-host*, *private-port*): Use these instead of *host* and the
  recently removed *port*. A web app needs to know its public address,
  and the private ports are part of its config.
  (*server-impl-args*): Redefine as a thunk to delay the dereferencing
  of config parameters like *private-host*.

* tekuti/page-helpers.scm (ensure-public-uri): New helper, uses the new
  conf vars to ensure that a value is a URI.
  (build-headers): New helper, like the old acons* without consing a
  rest list.
  (respond): Use the two new helpers.
  (atom-header, atom-entry): No need for server-name arg, as we know how
  to make a public URI.

* tekuti/page.scm (page-feed-atom): Adapt to no need to guess at the
  server-name.

* tekuti/web.scm (main-loop): Allow *server-impl-args* to be a thunk.
2010-11-22 23:33:08 +01:00
Andy Wingo
3ece90674a expanduser tweaks
* tekuti/util.scm (expanduser): Use passwd:name accessor, and geteuid as
  cuserid did.
2010-11-18 11:16:50 +01:00
Ramakrishnan Muthukrishnan
1692732222 get username from the password file instead of using `cuserid'.
* tekuti/util.scm (expanduser): Use the user id to fetch the
  username from the /etc/passwd file, so that the username is
  not chopped at eight characters.
2010-11-18 11:15:48 +01:00
Ramakrishnan Muthukrishnan
b8b1f47d65 Change wordpress import to use the newer wordpress database layout.
* wordpress_to_dir.py (all_posts): select only published posts.
  (post_categories): get the post category based on the new set
  of tables wp_terms, wp_term_relationships and wp_term_taxonomy.
2010-11-15 22:05:15 +01:00