Skip to content

Commit

Permalink
Merge pull request #10 from Itai-Nelken/beta
Browse files Browse the repository at this point in the history
Merge Beta into Main!
  • Loading branch information
Itai-Nelken authored Apr 24, 2021
2 parents 1c263f7 + 8a2280b commit 75f7bbf
Show file tree
Hide file tree
Showing 3 changed files with 486 additions and 350 deletions.
17 changes: 17 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -79,3 +79,20 @@ released version 0.6.0!

### 14/3/2021
Removed `/usr/local/` from the deb. all files copied from there are put in `/usr/` instead.

### ~15/3/2021-24/4/2021
**GIANT CHANGES AND IMPROVEMENTS!**
1) The install-deb function was depracated and removed, the clean-up function does the work now.
2) Updated the clean-up function.
3) Fixed some issues with the "$QBUILD" variable (where to compile QEMU).
4) Re-wrote the error function, now it foes the work of the warning and warning-sleep functions.
5) Improvements to the make-deb function and renamed it to cp-files, added error handling.
6) Added variables holding the escape character "codes" used to format text.
7) Completely re-wrote the ctrl_c function! now it know in what part of the script it was called, and cleans up according to that.
8) Added the "$CALLCOMMAND" variable that lets me set the name of the script to use in the help function.
9) Change to 'case' instead of 'if-then-elif-else' statment for the flags.
10) Added the 'maintainer=<string>' flag, so you can set the maintainer name when running the script!.
11) If user selected to compile QEMU, ask where.
12) bumped version to 0.7.0
13) print errors to `stderr`
**and much, much more I forgot to document...**
26 changes: 26 additions & 0 deletions input-from-flag-demo.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
#!/bin/bash

while [[ $# != 0 ]]; do
case "$1" in
-h|--help)
echo "TEST_SCRIPT to test flags."
echo " "
echo "./1.sh [options]"
echo " "
echo "options:"
echo "-h, --help show this help."
echo "--input="some-text" test to get text from a flag."
exit 0
;;
-i* | --input*)
export TEST=$(echo $1 | sed -e 's/^[^=]*=//g')
shift
;;
*)
echo "invalid option '$1'!"
break
;;
esac
done

echo $TEST
Loading

0 comments on commit 75f7bbf

Please sign in to comment.