#!/usr/bin/env sh # Create parseable data for the Winlink Activity Log (ICS 214) # You can paste the output of this script within the ICS 214 Winlink Form # Use `Paste Data from a Spreadsheet` in the ICS 214 form # # Author: Dominic Reich "OE7DRT" # Created: 2026-03-07 # # Changelog # 2026-03-08 # Added copy to clipboard on exit (forgot that before) # # LICENSE: MIT # # Copyright © 2026 Dominic Reich, OE7DRT # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the “Software”), to deal # in the Software without restriction, including without limitation the rights # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell # copies of the Software, and to permit persons to whom the Software is # furnished to do so, subject to the following conditions: # # The above copyright notice and this permission notice shall be included in # all copies or substantial portions of the Software. # # THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE # SOFTWARE. trap process 2 process() { if [ -z "${mylist}" ]; then echo -en 2>&1 "\n\nList is empty, aborting!\n" exit 0 fi cutline="--- 8< --- cut --- 8< --- cut --- 8< ---" echo -en "\n\n${cutline}\n\n${mylist}\n${cutline}\n" command -v wl-copy >/dev/null 2>&1 && { echo -en "${mylist}" | wl-copy -n; echo -en "\nThe list has also been copied to the clipboard\n"; } exit 0 } mylist="" counter=1 echo -en "This scipt gathers activity tasks used for the Winlink Activity Log (ICS 214) The numbered activities represent the current line number The actual time will be added as soon as you hit the enter key\n Press +C to stop and show the log\n\n" while : do if [ -n "${mylist}" ]; then echo -en "\nActivities so far:\n${mylist}\n" fi echo -en "${counter}. activity: " read mylist+="$(date +"""%Y-%m-%d %H:%M""")\t${REPLY}\n" ((counter++)) done