Browse Source

Function to tile pdf file

pull/17/head
Harish Karumuthil 3 years ago
parent
commit
b2aaaaa379
  1. 13
      home/.local/Apps/daily-utils/bin/hari-tools.sh

13
home/.local/Apps/daily-utils/bin/hari-tools.sh

@ -189,13 +189,6 @@ formatChromeCookie(){
cat /dev/stdin | cut -f 1,2 | xargs -l echo -e ".$1 TRUE / FALSE 0 " | sed 's/ /\t/g' cat /dev/stdin | cut -f 1,2 | xargs -l echo -e ".$1 TRUE / FALSE 0 " | sed 's/ /\t/g'
} }
# List available vaccine centers
cowin_list(){
curl -s -X GET \
"https://cdn-api.co-vin.in/api/v2/appointment/sessions/public/calendarByDistrict?district_id=303&date=$(date +'%d-%m-%Y' --date '1 day')" \
-H "accept: application/json" \
-H 'user-agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/88.0.4324.182 Safari/537.36' | jq
chromewayland(){ chromewayland(){
chromium --enable-features=UseOzonePlatform --ozone-platform=wayland chromium --enable-features=UseOzonePlatform --ozone-platform=wayland
} }
@ -227,6 +220,12 @@ json2csv(){
jq -r '(map(keys) | add | unique) as $cols | map(. as $row | $cols | map($row[.])) as $rows | $cols, $rows[] | @csv' jq -r '(map(keys) | add | unique) as $cols | map(. as $row | $cols | map($row[.])) as $rows | $cols, $rows[] | @csv'
} }
# pdfTile <input file> <nup 2x1>
# Tile input pdf in A4 sheet
pdfTile(){
pdfjam $1 --no-landscape --nup $2 --paper a4paper --suffix A4
}
# Setup autocomplete. run eval "$(THIS_FILE setup-autocomplete)" # Setup autocomplete. run eval "$(THIS_FILE setup-autocomplete)"
setup-autocomplete(){ setup-autocomplete(){

Loading…
Cancel
Save