summaryrefslogtreecommitdiff
path: root/TODO.org
blob: 1189584bd54b06034a3832865a522de060d5a55a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
* To-do list
** Allow for cache-busting assets
Providing the option to incorporate a hash of CSS, JS, etc. assets
into the URLs for those assets would be nice to ensure browser cache
misses when updates occur.  Using the query string for this would keep
the URL paths the same but the overall URL different.
** Allow #:prefix arg for 'blog' to be a procedure
In addition to a string. Will allow for custom placement of blog
posts. Some people want a hierarchy based on date, for example.
** Add blog theme example to manual
** Remove website directory
That is no longer used for the actual website
** Add docs for artifacts
** Allow collection pages to live in a different directory than posts.
** Feature request: Auto-reload pages when --watch detects changes
** External command processing
Hacky experimentation:
#+BEGIN_SRC scheme
  (use-modules (ice-9 match))

  (call-with-output-file "bloop.txt"
    (lambda (port)
      (match (primitive-fork)
        (0
         (close 1)
         (dup2 (fileno port) 1)
         (execlp "grep" "-e" "cat" "animals"))
        (pid
         (waitpid pid)))))

  (define (gcc c-file o-file)
    (list "gcc" "-o" o-file c-file))

  (define (external-artifact source destination command)
    (unless (file-exists? source)
      (error "input file does not exist" source))
    (make-artifact destination
                   (lambda (output)
                     (let ((command* (append command (list source))))
                       (format #t "run '~a' → '~a'~%"
                               (string-join command* " ")
                               destination)
                       (call-with-output-file output
                         (lambda (port)
                           ;; Run the command in a new process with
                           ;; stdout redirected into the output file.
                           (match (primitive-fork)
                             (0
                              (close 1)
                              (dup2 (fileno port) 1)
                              (apply execlp command*))
                             (pid
                              (match (waitpid pid)
                                ((_ . status)
                                 (unless (zero? (status:exit-val status))
                                   (error "command failed" command*))))))))))))

#+END_SRC
** Org-mode support
Just shell out to emacs using batch mode!