Merge pull request #3 from vitasam/scripts

Linux shell build script added
This commit is contained in:
Joe DF 2018-11-27 16:10:52 -05:00 committed by GitHub
commit aec205077b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 21 additions and 0 deletions

21
buildrun.sh Executable file
View File

@ -0,0 +1,21 @@
#!/bin/bash
{ set +x; } 2>/dev/null
mkdir bin 2>/dev/null
clear
echo compiling...
gcc test.c base64.c -o bin/test
gcc b64f.c base64.c -s -o bin/b64f
echo running...
bin/test
echo
echo Encoding test image "picture.png" to "picture.b64.txt"...
bin/b64f e picture.png picture.b64.txt
echo
echo Decoding test image from "picture.b64.txt" to "picture.b64.png"...
bin/b64f d picture.b64.txt picture.b64.png
echo Done.
echo See files manually if the programmed works correctly.