File tree Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change 7
7
set -v
8
8
9
9
read -r -d ' \n' -a news <<< ` find content/news/ -type d -printf " %f\n" | sort -n`
10
+ echo $news
11
+ echo ${news[-1]}
10
12
11
- last_news=` echo ${news[-1]} | sed -r s/0//`
12
- echo $last_news
13
- echo $(( last_news+ 1 ))
14
- news_to_create_simple=` echo $(( last_news+ 1 )) `
13
+ export last_news=` echo ${news[-1]} | sed -r s/0//`
14
+ export news_to_create_simple=` echo $(( last_news+ 1 )) `
15
15
echo $news_to_create_simple
16
16
printf " %#03s" $news_to_create_simple
17
- news_to_create=` printf " %#03s" $news_to_create_simple `
17
+ export news_to_create=` printf " %#03s" $news_to_create_simple `
18
18
echo $news_to_create
19
19
read -e -p " Do you want to create issue $news_to_create ? (y/n): " choice
20
20
21
21
[[ " $choice " != [Yy]* ]] && exit
22
22
23
23
echo " accepted"
24
24
25
- new_file=` echo " content/news/$news_to_create /index.md" `
25
+ export new_file=` echo " content/news/$news_to_create /index.md" `
26
26
27
27
echo $new_file
28
28
You can’t perform that action at this time.
0 commit comments