2025 refresh
This commit is contained in:
5
android/.shortcuts/1sshd.sh
Normal file
5
android/.shortcuts/1sshd.sh
Normal file
@@ -0,0 +1,5 @@
|
||||
#!/data/data/com.termux/files/usr/bin/bash
|
||||
|
||||
/data/data/com.termux/files/usr/bin/sshd
|
||||
echo "We need to pause this or the sshd will be killed with Termux."
|
||||
read -p "press enter to continue"
|
||||
@@ -1,5 +1,7 @@
|
||||
#!/data/data/com.termux/files/usr/bin/bash
|
||||
|
||||
targetpath=/data/data/com.termux/files/home/storage/documents/
|
||||
|
||||
cd ${targetpath}logseq-gitea/logseq
|
||||
|
||||
git stash
|
||||
37
android/.shortcuts/5it-status.sh
Normal file
37
android/.shortcuts/5it-status.sh
Normal file
@@ -0,0 +1,37 @@
|
||||
#/data/data/com.termux/files/usr/bin/bash
|
||||
|
||||
data=`/data/data/com.termux/files/usr/bin/curl -s -H "Content-Type: application/json;charset=utf-8" -H "Accept: application/json" -H "Authorization: Bearer a3761a4f-3d53-4206-a09a-54e73b157462" https://api.smartthings.com/devices/C097276A-4909-0000-0000-000000000000/status`
|
||||
|
||||
|
||||
echo
|
||||
echo
|
||||
echo
|
||||
|
||||
air_conditioner_mode=`echo ${data} | /data/data/com.termux/files/usr/bin/jq .components.main.airConditionerMode.airConditionerMode.value`
|
||||
echo "Air conditioner mode: ${air_conditioner_mode}"
|
||||
echo
|
||||
|
||||
|
||||
cooling_setpoint=`echo ${data} | /data/data/com.termux/files/usr/bin/jq .components.main.thermostatCoolingSetpoint.coolingSetpoint.value`
|
||||
echo "Cooling setpoint: ${cooling_setpoint}"
|
||||
echo
|
||||
|
||||
|
||||
switch=`echo ${data} | /data/data/com.termux/files/usr/bin/jq .components.main.switch.switch.value`
|
||||
echo "Switch (power): ${switch}"
|
||||
echo
|
||||
|
||||
|
||||
current_temperature=`echo ${data} | /data/data/com.termux/files/usr/bin/jq .components.main.temperatureMeasurement.temperature.value`
|
||||
echo "Current temperature: ${current_temperature}"
|
||||
echo
|
||||
|
||||
|
||||
|
||||
|
||||
echo
|
||||
echo
|
||||
echo
|
||||
|
||||
read -p "Press enter to continue" throwaway
|
||||
|
||||
4
android/.shortcuts/6it-on.sh
Normal file
4
android/.shortcuts/6it-on.sh
Normal file
@@ -0,0 +1,4 @@
|
||||
#/data/data/com.termux/files/usr/bin/bash
|
||||
|
||||
data=`/data/data/com.termux/files/usr/bin/curl -s -X POST -H "Content-Type: application/json;charset=utf-8" -H "Accept: application/json" -H "Authorization: Bearer a3761a4f-3d53-4206-a09a-54e73b157462" https://api.smartthings.com/devices/C097276A-4909-0000-0000-000000000000/commands -d '{"commands":[{"component":"main","capability":"switch","command":"on","arguments":[]}]}'`
|
||||
|
||||
4
android/.shortcuts/7it-off.sh
Normal file
4
android/.shortcuts/7it-off.sh
Normal file
@@ -0,0 +1,4 @@
|
||||
#/data/data/com.termux/files/usr/bin/bash
|
||||
|
||||
data=`/data/data/com.termux/files/usr/bin/curl -s -X POST -H "Content-Type: application/json;charset=utf-8" -H "Accept: application/json" -H "Authorization: Bearer a3761a4f-3d53-4206-a09a-54e73b157462" https://api.smartthings.com/devices/C097276A-4909-0000-0000-000000000000/commands -d '{"commands":[{"component":"main","capability":"switch","command":"off","arguments":[]}]}'`
|
||||
|
||||
8
android/.shortcuts/8it-config-auto.sh
Normal file
8
android/.shortcuts/8it-config-auto.sh
Normal file
@@ -0,0 +1,8 @@
|
||||
#/data/data/com.termux/files/usr/bin/bash
|
||||
|
||||
/data/data/com.termux/files/usr/bin/curl -s -X POST -H "Content-Type: application/json;charset=utf-8" -H "Accept: application/json" -H "Authorization: Bearer a3761a4f-3d53-4206-a09a-54e73b157462" https://api.smartthings.com/devices/C097276A-4909-0000-0000-000000000000/commands -d '{"commands":[{"component":"main","capability":"thermostatCoolingSetpoint","command":"setCoolingSetpoint","arguments":[24]}]}'
|
||||
|
||||
/data/data/com.termux/files/usr/bin/curl -s -X POST -H "Content-Type: application/json;charset=utf-8" -H "Accept: application/json" -H "Authorization: Bearer a3761a4f-3d53-4206-a09a-54e73b157462" https://api.smartthings.com/devices/C097276A-4909-0000-0000-000000000000/commands -d '{"commands":[{"component":"main","capability":"airConditionerFanMode","command":"setFanMode","arguments":["low"]}]}'
|
||||
|
||||
/data/data/com.termux/files/usr/bin/curl -s -X POST -H "Content-Type: application/json;charset=utf-8" -H "Accept: application/json" -H "Authorization: Bearer a3761a4f-3d53-4206-a09a-54e73b157462" https://api.smartthings.com/devices/C097276A-4909-0000-0000-000000000000/commands -d '{"commands":[{"component":"main","capability":"airConditionerMode","command":"setAirConditionerMode","arguments":["cool"]}]}'
|
||||
|
||||
8
android/.shortcuts/8it-config-max.sh
Normal file
8
android/.shortcuts/8it-config-max.sh
Normal file
@@ -0,0 +1,8 @@
|
||||
#/data/data/com.termux/files/usr/bin/bash
|
||||
|
||||
/data/data/com.termux/files/usr/bin/curl -s -X POST -H "Content-Type: application/json;charset=utf-8" -H "Accept: application/json" -H "Authorization: Bearer a3761a4f-3d53-4206-a09a-54e73b157462" https://api.smartthings.com/devices/C097276A-4909-0000-0000-000000000000/commands -d '{"commands":[{"component":"main","capability":"thermostatCoolingSetpoint","command":"setCoolingSetpoint","arguments":[18]}]}'
|
||||
|
||||
/data/data/com.termux/files/usr/bin/curl -s -X POST -H "Content-Type: application/json;charset=utf-8" -H "Accept: application/json" -H "Authorization: Bearer a3761a4f-3d53-4206-a09a-54e73b157462" https://api.smartthings.com/devices/C097276A-4909-0000-0000-000000000000/commands -d '{"commands":[{"component":"main","capability":"airConditionerFanMode","command":"setFanMode","arguments":["turbo"]}]}'
|
||||
|
||||
/data/data/com.termux/files/usr/bin/curl -s -X POST -H "Content-Type: application/json;charset=utf-8" -H "Accept: application/json" -H "Authorization: Bearer a3761a4f-3d53-4206-a09a-54e73b157462" https://api.smartthings.com/devices/C097276A-4909-0000-0000-000000000000/commands -d '{"commands":[{"component":"main","capability":"airConditionerMode","command":"setAirConditionerMode","arguments":["cool"]}]}'
|
||||
|
||||
8
android/.shortcuts/8it-config-stepan.sh
Normal file
8
android/.shortcuts/8it-config-stepan.sh
Normal file
@@ -0,0 +1,8 @@
|
||||
#/data/data/com.termux/files/usr/bin/bash
|
||||
|
||||
/data/data/com.termux/files/usr/bin/curl -s -X POST -H "Content-Type: application/json;charset=utf-8" -H "Accept: application/json" -H "Authorization: Bearer a3761a4f-3d53-4206-a09a-54e73b157462" https://api.smartthings.com/devices/C097276A-4909-0000-0000-000000000000/commands -d '{"commands":[{"component":"main","capability":"thermostatCoolingSetpoint","command":"setCoolingSetpoint","arguments":[24]}]}'
|
||||
|
||||
/data/data/com.termux/files/usr/bin/curl -s -X POST -H "Content-Type: application/json;charset=utf-8" -H "Accept: application/json" -H "Authorization: Bearer a3761a4f-3d53-4206-a09a-54e73b157462" https://api.smartthings.com/devices/C097276A-4909-0000-0000-000000000000/commands -d '{"commands":[{"component":"main","capability":"airConditionerFanMode","command":"setFanMode","arguments":["low"]}]}'
|
||||
|
||||
/data/data/com.termux/files/usr/bin/curl -s -X POST -H "Content-Type: application/json;charset=utf-8" -H "Accept: application/json" -H "Authorization: Bearer a3761a4f-3d53-4206-a09a-54e73b157462" https://api.smartthings.com/devices/C097276A-4909-0000-0000-000000000000/commands -d '{"commands":[{"component":"main","capability":"airConditionerMode","command":"setAirConditionerMode","arguments":["cool"]}]}'
|
||||
|
||||
22
android/.shortcuts/9it-set-temp.sh
Normal file
22
android/.shortcuts/9it-set-temp.sh
Normal file
@@ -0,0 +1,22 @@
|
||||
#/data/data/com.termux/files/usr/bin/bash
|
||||
|
||||
read -p "Enter desired temperature and press enter: " temperature
|
||||
|
||||
echo
|
||||
echo "Temperature set to: ${temperature}"
|
||||
|
||||
begging='{"commands":[{"component":"main","capability":"thermostatCoolingSetpoint","command":"setCoolingSetpoint","arguments":['
|
||||
rest="]}]}"
|
||||
command=${begging}${temperature}${rest}
|
||||
|
||||
echo
|
||||
echo
|
||||
echo "Command is:"
|
||||
echo ${command}
|
||||
echo
|
||||
echo
|
||||
|
||||
/data/data/com.termux/files/usr/bin/curl -X POST -H "Content-Type: application/json;charset=utf-8" -H "Accept: application/json" -H "Authorization: Bearer a3761a4f-3d53-4206-a09a-54e73b157462" https://api.smartthings.com/devices/C097276A-4909-0000-0000-000000000000/commands -d ${command} | /data/data/com.termux/files/usr/bin/jq
|
||||
|
||||
read -p "press enter to continue" throwaway
|
||||
|
||||
4
android/.shortcuts/termux-bck.sh
Normal file
4
android/.shortcuts/termux-bck.sh
Normal file
@@ -0,0 +1,4 @@
|
||||
#!/data/data/com.termux/files/usr/bin/bash
|
||||
tar -zcf /sdcard/termux-backup.tar.gz -C /data/data/com.termux/files ./home ./usr
|
||||
|
||||
|
||||
7
android/.shortcuts/termux-restore.sh
Normal file
7
android/.shortcuts/termux-restore.sh
Normal file
@@ -0,0 +1,7 @@
|
||||
#!/data/data/com.termux/files/usr/bin/bash
|
||||
termux-setup-storage
|
||||
|
||||
tar -zxf /sdcard/termux-backup.tar.gz -C /data/data/com.termux/files --recursive-unlink --preserve-permissions
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user