fixed awesome autostart dir. added wallpaper setter script. made no extension be filetype sh in neovim. renamed some scripts.
This commit is contained in:
13
env/.local/bin/scripts/math
vendored
Executable file
13
env/.local/bin/scripts/math
vendored
Executable file
@@ -0,0 +1,13 @@
|
||||
#!/bin/bash
|
||||
expression=$1
|
||||
precision=$2
|
||||
|
||||
if [ "$precision" == "" ]; then
|
||||
precision=1;
|
||||
fi;
|
||||
|
||||
# Perform arithmetic operation using awk
|
||||
result=$(awk "BEGIN {printf \"%.${precision}f\n\", $expression}" | sed 's/\.0$//')
|
||||
|
||||
# Print the result
|
||||
echo "$result"
|
||||
Reference in New Issue
Block a user