Merge branch 'test-ci' into master
This commit is contained in:
commit
24f5df77bb
35
.drone.yml
Normal file
35
.drone.yml
Normal file
@ -0,0 +1,35 @@
|
|||||||
|
kind: pipeline
|
||||||
|
name: default
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- name: build
|
||||||
|
image: silex/emacs:27
|
||||||
|
commands:
|
||||||
|
- pwd
|
||||||
|
- ls -ahl
|
||||||
|
- which emacs
|
||||||
|
- emacs --script export.el
|
||||||
|
|
||||||
|
- name: deploy
|
||||||
|
image: appleboy/drone-scp
|
||||||
|
settings:
|
||||||
|
host:
|
||||||
|
from_secret: ssh_host
|
||||||
|
target:
|
||||||
|
from_secret: ssh_target
|
||||||
|
source:
|
||||||
|
- !org/config/LICENSE.md
|
||||||
|
- org/config/*.html
|
||||||
|
strip_components: 2
|
||||||
|
username:
|
||||||
|
from_secret: ssh_username
|
||||||
|
password:
|
||||||
|
from_secret: ssh_password
|
||||||
|
port:
|
||||||
|
from_secret: ssh_port
|
||||||
|
when:
|
||||||
|
branch:
|
||||||
|
- master
|
||||||
|
event:
|
||||||
|
exclude:
|
||||||
|
- pull_request
|
21
export.el
Executable file
21
export.el
Executable file
@ -0,0 +1,21 @@
|
|||||||
|
#!/usr/bin/emacs --script
|
||||||
|
(require 'package)
|
||||||
|
(add-to-list 'package-archives '("melpa" . "https://melpa.org/packages/") t)
|
||||||
|
(package-initialize)
|
||||||
|
(package-refresh-contents)
|
||||||
|
(package-install 'htmlize)
|
||||||
|
(package-install 's)
|
||||||
|
(require 's)
|
||||||
|
(setq org-confirm-babel-evaluate nil)
|
||||||
|
(let* ((files (mapcar #'expand-file-name
|
||||||
|
(file-expand-wildcards "org/config/*.org"))))
|
||||||
|
(mapc (lambda (file)
|
||||||
|
(message (format "==========\nExporting %S\n==========" file))
|
||||||
|
(with-current-buffer (find-file file)
|
||||||
|
(org-html-export-to-html)))
|
||||||
|
files))
|
||||||
|
(let* ((files (mapcar #'expand-file-name
|
||||||
|
(file-expand-wildcards "org/config/*.html~"))))
|
||||||
|
(mapc (lambda (file)
|
||||||
|
(delete-file file))
|
||||||
|
files))
|
Loading…
Reference in New Issue
Block a user