aboutsummaryrefslogtreecommitdiff
path: root/modules/follow/main.sh
blob: 2da589d5134db842cae5758f244cb6cc3ce4401c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
#!/usr/bin/env bash
##
## You can maintain a list of friendly zchains or ids
##
## Usage:
##
##    -h, --help                  Prints this help message
##    -f, --follow                Adds a ... to your follow list
##    -l, --list                  Shows a list of your followings
##    -u, --unfollow              Unfollows a ...
##
fullprogrampath="$(realpath $0)"
PROGRAM="$(realpath $0 | rev |cut -d '/' -f 2 | rev)"
descriptionString="Following stuff"

source $AK_LIBDIR/_ak_log
source $AK_LIBDIR/_ak_script
source $AK_MODULESDIR/$PROGRAM/lib.sh

if [ ! -z $1 ]
then
    case $1 in
        -h | --help) _ak_usage; exit;;
        -f | --follow) _ak_follow_follow $2; exit;;
        -l | --list) _ak_follow_list $2; exit;;
        -u | --unfollow) _ak_follow_unfollow $2; exit;;
        * ) _ak_usage;;
    esac
else _ak_usage
fi