scripts

Scripts for general automations
git clone git://git.laack.co/scripts.git
Log | Files | Refs

commit b40dfac4140e36560838d0c4e3074097cd58da95
parent 37d4129d5f124ce4078818469dbe584a7147ac90
Author: Andrew Laack <andrew@laack.co>
Date:   Mon,  9 Nov 2026 22:43:33 -0600

Basic scripts for creating a task stack

Diffstat:
Anote-taking/peek | 7+++++++
Anote-taking/pop | 7+++++++
Anote-taking/push | 11+++++++++++
3 files changed, 25 insertions(+), 0 deletions(-)

diff --git a/note-taking/peek b/note-taking/peek @@ -0,0 +1,7 @@ +#!/bin/bash + +if [ -n "$STACK_FILE" ]; then + head -n 1 $STACK_FILE +else + echo "No STACK_FILE specified" +fi diff --git a/note-taking/pop b/note-taking/pop @@ -0,0 +1,7 @@ +#!/bin/bash + +if [ -n "$STACK_FILE" ]; then + tail -n +2 "$STACK_FILE" > "$STACK_FILE.tmp" && mv "$STACK_FILE.tmp" "$STACK_FILE" +else + echo "No STACK_FILE specified" +fi diff --git a/note-taking/push b/note-taking/push @@ -0,0 +1,11 @@ +#!/bin/bash + +if [ -n "$1" ]; then + if [ -n "$STACK_FILE" ]; then + echo $1 >> $STACK_FILE + else + echo "No STACK_FILE specified" + fi +else + echo "usage: push {task text}" +fi