summaryrefslogtreecommitdiff
path: root/README
diff options
context:
space:
mode:
Diffstat (limited to 'README')
-rw-r--r--README40
1 files changed, 40 insertions, 0 deletions
diff --git a/README b/README
new file mode 100644
index 0000000..1980657
--- /dev/null
+++ b/README
@@ -0,0 +1,40 @@
+To develop, run:
+
+ nix-shell
+
+For API setup instructions:
+
+ twitter-bot --instructions
+
+To install and deploy:
+
+ nix-build .
+ nix-env -i ./result
+
+Now you can copy the systemd unit file to `~/.config/systemd/user/` and enable:
+
+ systemctl --user enable twitter-bot.service twitter-bot.timer
+
+Example systemd unit file:
+
+ [Unit]
+ Description=Zulip Twitter Bot
+
+ [Service]
+ Type=oneshot
+ ExecStart=/home/ben/.nix-profile/bin/twitter-bot --dry-run --stream investing --twitter-name michaeljburry
+ ExecStart=/home/ben/.nix-profile/bin/twitter-bot --dry-run --stream bitcoin --twitter-name 100trillionUSD
+
+ [Install]
+ WantedBy=basic.target
+
+Example timer unit, running every 5 minutes:
+
+ [Unit]
+ Description=Run zulip bot
+
+ [Timer]
+ OnCalendar=*-*-* *:0/5
+
+ [Install]
+ WantedBy=timer.target