ShareShortcuts
Fork “I.B.L.O.S”

Built something new on top of this Shortcut? Share it as a fork: it becomes a Shortcut of your own, which you manage, and both pages link to each other so shortgram gets credit.

  1. 1Get the Shortcut and change it in the Shortcuts app. Give it a name of its own.
  2. 2Share it from the Shortcuts app and copy the iCloud link.
  3. 3Come back here, paste the link and describe what is different, e.g. “Added a step that uses Apple Intelligence to personalise the text.”
Downloads
63K
Saved
1
Actions
27
Category
Utilities
Version
1.0
Language
EN

Internal

Battery

Level

Optimization

System

This is my go at a PowerSaver # I don’t suggest using this shortcut if you have iPadOS 15 or newer because the newer OS has it’s own low power mode

What's New

Version 1.0

First release

Version History
1.0 Jun 10, 2020

First release

What it does

27 actions
  1. Comment
    This gets the device model
  2. Get Device Details
  3. Set Variable
    DeviceModel
  4. Comment
    This gets the device battery level
  5. Get Battery Level
  6. Set Variable
    BatteryLevel
  7. Comment
    Yes or No if your device is charging
  8. Battery Status
    com.alexhay.ToolboxProForShortcuts
  9. Set Variable
    BatteryStatus
  10. If
  11. If
  12. Show Notification
    Plug in your device soon!
  13. Comment
    If your device is iPhone it will just run low power mode
  14. If
  15. Set Low Power Mode
  16. If
  17. Comment
    If your device is anything but iPhone it will turn Bluetooth off, turn of Wi-Fi, Turn reduce motion on, set brightness to 10%
  18. Set Bluetooth
  19. Set Wi-Fi
  20. Comment
    Turning reduce motion on might help or not To get to reduce motion go to: Setting -> Accessibility -> Motion (This is on iPad mini)
  21. Toggle Reduce Motion
    com.apple.AccessibilityUtilities.AXSettingsShortcuts
  22. Set Brightness
  23. If
  24. Set Bluetooth
  25. Set Wi-Fi
  26. Toggle Reduce Motion
    com.apple.AccessibilityUtilities.AXSettingsShortcuts
  27. Set Brightness

View as code
Beta

Every action of this Shortcut written out as Cherri, a programming language for Shortcuts. Great for learning how it works.

#define mac false
#include 'actions/device'
#define glyph battery

// This gets the device model

getDeviceDetail("Device Model")
@DeviceModel
// This gets the device battery level

getBatteryLevel()
@BatteryLevel
// Yes or No if your device is charging

rawAction("com.alexhay.ToolboxProForShortcuts.BatteryStatusIntent", {
	"batteryState": "isCharging"
})
@BatteryStatus

if @BatteryStatus contains "Yes" {
	if @BatteryLevel <= 20 {
		showNotification("Plug in your device soon!", @BatteryLevel)
		// If your device is iPhone it will just run low power mode

		if @DeviceModel contains "iPhone" {
			setLowPowerMode(false)
		} else {
			// If your device is anything but iPhone it will turn Bluetooth off, turn of Wi-Fi, Turn reduce motion on, set brightness to 10%

			setBluetooth(0)
			setWifi(0)
			/*
			Turning reduce motion on might help or not
			To get to reduce motion go to:
			Setting -> Accessibility -> Motion
			(This is on iPad mini)
			*/
			setReduceMotion(1)
			setBrightness(0.10381356)
		}
	} else {
		setBluetooth(false)
		setWifi(false)
		toggleReduceMotion()
		setBrightness(nil)
	}
}
Open in Cherri Playground Decompiled with cherri 2.3.0 (GPL-2.0). May need small fixes before it compiles.

Ratings & Reviews

Write a Review
–
out of 5
★★★★★
★★★★
★★★
★★
★
0 ratings

No reviews yet. Be the first to share what you think!

Advertisement

More by shortgram

See All

You Might Also Like

See All
Advertisement