blob: 84aea74e5c540c781a11f20d4ce815ea94bc4560 (
plain) (
blame)
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
31
32
33
34
35
36
37
38
39
40
|
#!/bin/bash
#Description: Looks into your JOBDIR folders for jobs you marked as considering, presents them to you for research, then asks your opinion on them.
#Axioms: JOBDIR
#Dependencies: joblook
numofjobs=1
consideringjob="$(find /home/"$USER"/Documents/Jobs/Considering -maxdepth 1 -type f | shuf | head -1)"
if [[ $# = 0 ]]
then
grep "URL : " "$consideringjob"|sed -e 's/URL : //g'|xargs xdg-open
read -r -p "Are you interested? (y/n): " Choice
if [ "$Choice" = 'y' ]
then
mkdir /home/"$USER"/Documents/Jobs/Applying/"$(basename "$consideringjob" .txt)"
mv -v "$consideringjob" /home/"$USER"/Documents/Jobs/Applying/"$(basename "$consideringjob" .txt)"/"$(basename "$consideringjob")"
elif [ "$Choice" = 'n' ]
then
rm "$consideringjob"
fi
fi
while [[ "$numofjobs" -le "$1" ]]
do
grep "URL : " "$consideringjob"|sed -e 's/URL : //g'|xargs xdg-open
read -r -p "Are you interested? (y/n): " Choice
if [ "$Choice" = 'y' ]
then
mkdir /home/"$USER"/Documents/Jobs/Applying/"$(basename "$consideringjob" .txt)"
mv -v "$consideringjob" /home/"$USER"/Documents/Jobs/Applying/"$(basename "$consideringjob" .txt)"/"$(basename "$consideringjob")"
elif [ "$Choice" = 'n' ]
then
rm "$consideringjob"
fi
consideringjob="$(find /home/"$USER"/Documents/Jobs/Considering -maxdepth 1 -type f | shuf | head -1)"
numofjobs=$numofjobs+1
done
|