aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
-rw-r--r--%HOME%/.config/systemd/user/pull.service11
-rw-r--r--%HOME%/.config/systemd/user/pull.timer10
-rw-r--r--.gitignore1
3 files changed, 22 insertions, 0 deletions
diff --git a/%HOME%/.config/systemd/user/pull.service b/%HOME%/.config/systemd/user/pull.service
new file mode 100644
index 0000000..6970520
--- /dev/null
+++ b/%HOME%/.config/systemd/user/pull.service
@@ -0,0 +1,11 @@
+[Unit]
+Description=Run pull.sh
+Wants=ssh-agent.service
+
+[Service]
+Type=simple
+WorkingDirectory=/srv/git
+ExecStartPre=/usr/bin/truncate --size=0K -- /srv/git/pull.log
+ExecStart=/srv/git/pull.sh
+StandardOutput=file:/srv/git/pull.log
+StandardError=inherit
diff --git a/%HOME%/.config/systemd/user/pull.timer b/%HOME%/.config/systemd/user/pull.timer
new file mode 100644
index 0000000..b39b357
--- /dev/null
+++ b/%HOME%/.config/systemd/user/pull.timer
@@ -0,0 +1,10 @@
+[Unit]
+Description=Run pull.sh periodically
+
+[Timer]
+Persistent=false
+OnCalendar=daily
+AccuracySec=1
+
+[Install]
+WantedBy=timers.target
diff --git a/.gitignore b/.gitignore
index 2ed70c8..b13c5f3 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,2 +1,3 @@
+/links.bin
/pull.log
/repos/