Escanea con tu iPhone para instalar
Vista previa
This shortcut allows you to add another layer of security on your apps.
READ HELP FOR INFO ON SETUP
Features
- Able to use different passcodes for each app
- Toggle locks
- Change Re-lock interval
Novedades
Versión 1.0
First release
Qué hace
317 acciones-
Dictionary
-
Set VariableMain Variables
-
Get Text from Input
-
If
-
Text
-
Set VariablefastLaunch
-
If
-
List
-
Repeat with Each
-
If
-
Set Variablefunction
-
Replace Text
-
Replace Text
-
Split Text
-
Set VariableINPUT
-
If
-
Text
-
Repeat with Each
-
Set Valuedk.simonbs.DataJar
-
Stop This Shortcut
-
If
-
Text
-
Repeat with Each
-
Set Valuedk.simonbs.DataJar
-
Stop This Shortcut
-
If
-
Text
-
Repeat with Each
-
Get Valuedk.simonbs.DataJar
-
If
-
Text
-
If
-
Text
-
Set Valuedk.simonbs.DataJar
-
Stop This Shortcut
-
CommentDeveloper Functions (**) DO NOT use these!
-
If
-
Get My Shortcuts
-
Get Name
-
Repeat with Each
-
Get Index Of List Itemcom.sindresorhus.Actions
-
Text
-
If
-
Add to Variable
-
Stop and Output
-
If
-
Check If Value Existsdk.simonbs.DataJar
-
If
-
Ask for InputEnter New Master Password
-
If
-
Text
-
If
-
Base64 Encode
-
Set Valuedk.simonbs.DataJar
-
Text
-
Stop and Output
-
If
-
Get Valuedk.simonbs.DataJar
-
If
-
Get Clipboard
-
Set VariableprevClipboard
-
Authenticatecom.sindresorhus.Actions
-
Wait to Return
-
Hide Shortcutscom.sindresorhus.Actions
-
Get Clipboard
-
Copy to Clipboard
-
Get Clipboard
-
Stop and Output
-
Base64 Encode
-
Set VariablemasterPasscode
-
Ask for InputEnter Master Password
-
If
-
Text
-
If
-
Text
-
Stop and Output
-
Stop This Shortcut
-
If
-
Split Text
-
Get Numbers from Input
-
Split Text
-
Get Numbers from Input
-
Repeat with Each
-
Get Item from List
-
If
-
Text
-
Stop and Output
-
Text
-
Stop and Output
-
Check If Value Existsdk.simonbs.DataJar
-
If
-
Number
-
Set Valuedk.simonbs.DataJar
-
Get Valuedk.simonbs.DataJar
-
Set VariablewaitTime
-
If
-
Text
-
If
-
If
-
Text
-
If
-
Text
-
If
-
Get File
-
If
-
Dictionary
-
Pretty Print Dictionariescom.sindresorhus.Actions
-
Save File
-
Set VariablelastVersion
-
Get Variable
-
If
-
Get Dictionary from Input
-
Set VariablelastVersion
-
Set Dictionary Value
-
Pretty Print Dictionariescom.sindresorhus.Actions
-
Save File
-
Get Variable
-
Set Variabledetails
-
If
-
If
-
CommentIf you just updated
-
Text
-
Run ShortcutApp Locker
-
If
-
Get Dictionary Value
-
Text
-
Run ShortcutApp Locker
-
If
-
Repeat with Each
-
Text
-
Text
-
Show AlertOther Shortcuts Required
-
Repeat with Each
-
Get Dictionary Value
-
Open URLs
-
Stop This Shortcut
-
Choose from MenuApp Locker v…
-
Choose from MenuToggle Locks
-
Text
-
Run ShortcutApp Locker
-
If
-
If
-
Text
-
Run ShortcutApp Locker
-
Stop This Shortcut
-
Get Keysdk.simonbs.DataJar
-
Filter Files
-
Set VariablemyApps
-
Repeat with Each
-
Get Valuedk.simonbs.DataJar
-
If
-
Text
-
If
-
Text
-
Text
-
Add to Variable
-
Choose from List
-
Set Variablechoices
-
Repeat with Each
-
Replace Text
-
Replace Text
-
Add to Variable
-
Repeat with Each
-
Get Valuedk.simonbs.DataJar
-
If
-
Text
-
If
-
Text
-
Set Valuedk.simonbs.DataJar
-
Text
-
Run ShortcutApp Locker
-
Choose from MenuManage Passwords
-
Text
-
Run ShortcutApp Locker
-
If
-
If
-
Text
-
Run ShortcutApp Locker
-
Stop This Shortcut
-
Get Keysdk.simonbs.DataJar
-
Filter Files
-
Set VariablemyApps
-
Text
-
Add To Listcom.sindresorhus.Actions
-
Set VariablemyApps
-
Choose from List
-
If
-
Text
-
If
-
Text
-
Set Variablepath
-
Get Valuedk.simonbs.DataJar
-
If
-
Number
-
If
-
Base64 Encode
-
Ask for Input…
-
If
-
Choose from MenuWhat to do with …?
-
Choose from MenuTouch/Face ID
Ver como código
Todas las acciones de este atajo escritas en Cherri, un lenguaje de programación para Atajos. Ideal para aprender cómo funciona.
#include 'actions/text'
#define color darkorange
#define glyph lock
@MainVariables = {
"Dep": {
"Open App URL": "https://routinehub.co/shortcut/13560/"
},
"Name": "App Locker",
"ShareShortcuts ID": "13384",
"Version": "1.2.4"
}
const origText = getText(ShortcutInput)
if origText == "**FAST_LAUNCH" {
@fastLaunch = "true"
}
if origText endsWith ")" {
const functions = list("**askMaster", "**justUpdated", "**dependOutput", "lock", "unlock", "toggle")
for _ in functions {
if origText beginsWith "{@RepeatItem}(" {
@function = @RepeatItem
}
}
replaceText("{@function}(", "", origText)
const UpdatedText = replaceText(")", "")
splitText(UpdatedText)
@INPUT
if @function == "lock" {
const Text = "true"
for _ in @INPUT {
rawAction("dk.simonbs.DataJar.SetValueIntent", {
"keyPath": "AppLocker.apps.{@RepeatItem}.locked",
"overwriteStrategy": "alwaysAllow",
"values": "Text"
})
}
stop()
}
if @function == "unlock" {
const Text1 = "false"
for _ in @INPUT {
rawAction("dk.simonbs.DataJar.SetValueIntent", {
"keyPath": "AppLocker.apps.{@RepeatItem}.locked",
"overwriteStrategy": "alwaysAllow",
"values": "Text1"
})
}
stop()
}
if @function == "toggle" {
const Text2 = "false"
for _ in @INPUT {
rawAction("dk.simonbs.DataJar.GetValueIntent", {
"fallbackValues": "Text2",
"keyPath": "AppLocker.apps.{@RepeatItem}.locked"
})
if Value == {
} else {
}
rawAction("dk.simonbs.DataJar.SetValueIntent", {
"keyPath": "AppLocker.apps.{@INPUT}.locked",
"overwriteStrategy": "alwaysAllow",
"values": "IfResult"
})
}
stop()
}
/*
Developer Functions (**)
DO NOT use these!
*/
if @function == "**dependOutput" {
const MyShortcuts = getShortcuts()
const Name = getName(MyShortcuts)
for _ in @INPUT {
rawAction("com.sindresorhus.Actions.GetIndexOfListItem", {
"AppIntentDescriptor": "",
"item": "{@RepeatItem}",
"list": "Name"
})
const Text3 = "-1"
if IndexOfListItem == Text3 {
@OUTPUT = @RepeatItem
}
}
output(@OUTPUT)
}
if @function == "**askMaster" {
rawAction("dk.simonbs.DataJar.CheckIfValueExistsIntent", {
"keyPath": "AppLocker.pass"
})
if ValueExists == 0 {
const ProvidedInput = prompt("Enter New Master Password", "Number")
if ProvidedInput < 0 {
} else {
base64Encode(ProvidedInput)
}
rawAction("dk.simonbs.DataJar.SetValueIntent", {
"keyPath": "AppLocker.pass",
"overwriteStrategy": "alwaysAllow",
"values": "IfResult1"
})
output()
} else {
rawAction("dk.simonbs.DataJar.GetValueIntent", {
"keyPath": "AppLocker.pass"
})
if Value1 == "BIO AUTH" {
getClipboard()
@prevClipboard
rawAction("com.sindresorhus.Actions.Authenticate", {
"AppIntentDescriptor": "",
"openURL": ""
})
waitToReturn()
rawAction("com.sindresorhus.Actions.HideShortcutsAppIntent", {
"AppIntentDescriptor": ""
})
const AuthResult = getClipboard()
setClipboard(@prevClipboard, true)
getClipboard()
output(AuthResult)
}
base64Encode(Value1)
@masterPasscode
const ProvidedInput1 = prompt("Enter Master Password", "Number")
if ProvidedInput1 == @masterPasscode {
} else {
}
output()
}
stop()
}
if @function == "**justUpdated" {
const SplitText = splitText(@MainVariables, ".")
const version = getNumbers(SplitText)
const SplitText1 = splitText(@INPUT, ".")
const lastVersion = getNumbers(SplitText1)
for _ in version {
const ItemFromList = getListItem(lastVersion, @RepeatIndex)
if @RepeatItem > ItemFromList {
output()
}
}
output()
}
}
rawAction("dk.simonbs.DataJar.CheckIfValueExistsIntent", {
"keyPath": "AppLocker.waitTime"
})
if ValueExists1 == 0 {
const Number = 80
rawAction("dk.simonbs.DataJar.SetValueIntent", {
"keyPath": "AppLocker.waitTime",
"overwriteStrategy": "alwaysAllow",
"values": "Number"
})
}
rawAction("dk.simonbs.DataJar.GetValueIntent", {
"keyPath": "AppLocker.waitTime"
})
@waitTime
if !ShortcutInput {
} else {
if @fastLaunch == {
} else {
}
}
if OpenMenu == {
const File = getFile("Local Shortcuts/AppLocker/details.json", false)
if !File {
const defaultDetails = {
"version": "{@MainVariables['Version']}"
}
rawAction("com.sindresorhus.Actions.PrettyPrintDictionariesIntent", {
"AppIntentDescriptor": "",
"dictionaries": "defaultDetails",
"dictionary": "defaultDetails"
})
saveFile("Local Shortcuts/AppLocker/details.json", PrettyPrintedDictionary, true)
@lastVersion = nil
// TODO: Get Variable not supported: Assign variable here to 'defaultDetails'.
} else {
const Dictionary = getDictionary(File)
@lastVersion = Dictionary['version']
const Dictionary1 = setValue(Dictionary, "version", @MainVariables['Version'])
rawAction("com.sindresorhus.Actions.PrettyPrintDictionariesIntent", {
"AppIntentDescriptor": "",
"dictionaries": "Dictionary",
"dictionary": "Dictionary1"
})
saveFile("Local Shortcuts/AppLocker/details.json", PrettyPrintedDictionary1, true)
// TODO: Get Variable not supported: Assign variable here to 'Dictionary1'.
}
@details
if @fastLaunch == {
} else {
// If you just updated
const Text4 = "**justUpdated({@lastVersion})"
const ShortcutResult = runSelf(Text4)
if ShortcutResult == {
}
const Dependencies = getKeys(@MainVariables)
const Text5 = "**dependOutput({Dependencies})"
const ShortcutResult1 = runSelf(Text5)
if ShortcutResult1 {
for _ in Dependencies {
}
alert(, "Other Shortcuts Required")
for _ in ShortcutResult1 {
}
openURL(RepeatResults)
stop()
}
}
menu "App Locker v{@MainVariables['Version']}" {
item "Toggle Locks":
const Text6 = "**askMaster()"
const ShortcutResult2 = runSelf(Text6)
if ShortcutResult2 == {
} else {
const Text7 = "**FAST_LAUNCH"
runSelf(Text7)
stop()
}
rawAction("dk.simonbs.DataJar.GetKeysIntent", {
"errorWhenValueNotFound": false,
"keyPath": "AppLocker.apps",
"source": "dictionary"
})
filterFiles(Keys, "Name", "A to Z")
@myApps
for _ in @myApps {
rawAction("dk.simonbs.DataJar.GetValueIntent", {
"keyPath": "AppLocker.apps.{@RepeatItem}.locked"
})
if Value2 == {
} else {
}
@choices += "{} {@RepeatItem}"
}
const ChosenItem = chooseFromList(@choices, "Toggle which locks?", true)
@choices = nil
for _ in ChosenItem {
replaceText("🔒 ", "", @RepeatItem, false, false)
replaceText("🔓 ", "", false, false)
@choices
}
for _ in @choices {
rawAction("dk.simonbs.DataJar.GetValueIntent", {
"keyPath": "AppLocker.apps.{@RepeatItem}.locked"
})
if Value3 == {
} else {
}
rawAction("dk.simonbs.DataJar.SetValueIntent", {
"keyPath": "AppLocker.apps.{@RepeatItem}.locked",
"overwriteStrategy": "alwaysAllow",
"values": "IfResult2"
})
}
const Text8 = "**FAST_LAUNCH"
runSelf(Text8)
item "Manage Passwords":
const Text9 = "**askMaster()"
const ShortcutResult3 = runSelf(Text9)
if ShortcutResult3 == {
} else {
const Text10 = "**FAST_LAUNCH"
runSelf(Text10)
stop()
}
rawAction("dk.simonbs.DataJar.GetKeysIntent", {
"errorWhenValueNotFound": false,
"keyPath": "AppLocker.apps",
"source": "dictionary"
})
filterFiles(Keys1, "Name", "A to Z")
@myApps
const Text11 = "Master Passcode"
rawAction("com.sindresorhus.Actions.AddToListIntent", {
"AppIntentDescriptor": "",
"item": "Text11",
"list": "@myApps",
"prepend": 1
})
@myApps
const ChosenApp = chooseFromList(@myApps, "Manage which password?")
if ChosenApp == "Master Passcode" {
} else {
}
@path = "AppLocker.apps.{ChosenApp}"
rawAction("dk.simonbs.DataJar.GetValueIntent", {
"keyPath": "{@path}.pass"
})
if Value4 == "BIO AUTH" {
} else {
base64Encode(Value4)
}
const ProvidedInput2 = prompt(ChosenApp, "Number")
if ProvidedInput2 < 0 {
menu "What to do with {ChosenApp}?" {
item "Touch/Face ID":
item "Remove Lock":
if ChosenApp == "Master Passcode" {
rawAction("dk.simonbs.DataJar.DeleteValueIntent", {
"deleteStrategy": "alwaysAllow",
"errorWhenValueNotFound": false,
"keyPath": "{@path}.pass"
})
} else {
rawAction("dk.simonbs.DataJar.DeleteValueIntent", {
"deleteStrategy": "alwaysAllow",
"errorWhenValueNotFound": false,
"keyPath": "{@path}"
})
}
const Text12 = "**FAST_LAUNCH"
runSelf(Text12)
stop()
}
} else {
const SplitText2 = splitText(ProvidedInput2, ",")
const CombinedText = joinText(SplitText2, "Custom")
base64Encode(CombinedText)
}
rawAction("dk.simonbs.DataJar.SetValueIntent", {
"keyPath": "{@path}.pass",
"overwriteStrategy": "alwaysAllow",
"valueConversionMode": "text",
"values": "IfResult4"
})
const Text13 = "**FAST_LAUNCH"
runSelf(Text13)
item "Change Re-lock Interval":
const Text14 = "**askMaster()"
const ShortcutResult4 = runSelf(Text14)
if ShortcutResult4 == {
} else {
const Text15 = "**FAST_LAUNCH"
runSelf(Text15)
stop()
}
const ProvidedInput3 = prompt("Change Interval to… (sec)", "Number")
rawAction("dk.simonbs.DataJar.SetValueIntent", {
"keyPath": "AppLocker.waitTime",
"values": "ProvidedInput3"
})
const Text16 = "**FAST_LAUNCH"
runSelf(Text16)
item "Check for Updates":
getDeviceDetail("System Version")
const ContentsOfURL = jsonRequest("https://updatekit.mikebeas.com/v1", "POST", {
"ios": "{}",
"shortcut": {
"id": "{@MainVariables['ShareShortcuts ID']}",
"module": "shareshortcuts",
"version": "{@MainVariables['Version']}"
}
})
const DictionaryValue = getValue(ContentsOfURL, "update")
if DictionaryValue == {
menu {
item "Install":
openURL(ContentsOfURL['payload.download'])
stop()
item "Changes":
show(ContentsOfURL['payload.notes'])
}
} else {
alert("No update available", "{@MainVariables['Name']} is up to date.")
}
const Text17 = "**FAST_LAUNCH"
runSelf(Text17)
item "Help":
const File1 = getFile("Local Shortcuts/AppLocker/helpVideo.mp4", false)
if !File1 {
rawAction("com.sindresorhus.Actions.IsOnlineIntent", {
"AppIntentDescriptor": ""
})
if IsOnline == 1 {
const ContentsOfURL1 = downloadURL("https://drive.google.com/uc?id=1Lz8QAfC36t4pOX8shTox07PW34SY1w4A&export=download")
saveFile("Local Shortcuts/AppLocker/helpVideo.mp4", ContentsOfURL1)
}
}
const helpVideo = getFile("Local Shortcuts/AppLocker/helpVideo.mp4", false)
show()
if helpVideo {
quicklook(helpVideo)
} else {
alert("Could not fetch photo", "Connection Error")
}
alert("Would you like to add some?", "Change Automations")
openURL("shortcuts://automations")
}
stop()
}
@APP = origText
if @APP == "Actions" {
alert("\"Actions\" is not a legal statement.", "An error occurred")
stop()
}
rawAction("dk.simonbs.DataJar.CheckIfValueExistsIntent", {
"keyPath": "AppLocker.apps.{@APP}.locked"
})
if ValueExists2 == 0 {
const Text18 = "true"
rawAction("dk.simonbs.DataJar.SetValueIntent", {
"keyPath": "AppLocker.apps.{@APP}.locked",
"overwriteStrategy": "alwaysAllow",
"values": "Text18"
})
}
rawAction("dk.simonbs.DataJar.GetValueIntent", {
"keyPath": "AppLocker.apps.{@APP}.locked"
})
@locked
if @locked == {
} else {
stop()
}
rawAction("com.sindresorhus.Actions.DateToUnixTimeIntent", {
"AppIntentDescriptor": "",
"date": "{CurrentDate}"
})
@now
const CalculationResult = @waitTime + 120
const CalculationResult1 = @now - CalculationResult
rawAction("dk.simonbs.DataJar.GetValueIntent", {
"fallbackValues": "CalculationResult1",
"keyPath": "AppLocker.apps.{@APP}.lastUsed"
})
@lastUsed
const CalculationResult2 = @now - @lastUsed
if CalculationResult2 <= @waitTime {
rawAction("dk.simonbs.DataJar.SetValueIntent", {
"keyPath": "AppLocker.apps.{@APP}.lastUsed",
"overwriteStrategy": "alwaysAllow",
"valueConversionMode": "automatic",
"values": "@now"
})
stop()
}
rawAction("dk.simonbs.DataJar.CheckIfValueExistsIntent", {
"keyPath": "AppLocker.apps.{@APP}.pass"
})
if ValueExists3 == 0 {
const ProvidedInput4 = prompt("Enter New Passcode for {@APP}", "Number")
if ProvidedInput4 < 0 {
} else {
base64Encode(ProvidedInput4)
}
rawAction("dk.simonbs.DataJar.SetValueIntent", {
"keyPath": "AppLocker.apps.{@APP}.pass",
"values": "IfResult5"
})
stop()
}
rawAction("dk.simonbs.DataJar.GetValueIntent", {
"keyPath": "AppLocker.apps.{@APP}.pass"
})
if Value5 == "BIO AUTH" {
getClipboard()
@prevClipboard
rawAction("com.sindresorhus.Actions.Authenticate", {
"AppIntentDescriptor": "",
"openURL": ""
})
waitToReturn()
const Clipboard = getClipboard()
if Clipboard == {
} else {
setClipboard(@prevClipboard)
getClipboard()
stop()
}
setClipboard(@prevClipboard)
getClipboard()
} else {
openURL("shortcuts://run-shortcut?name=Open%20App%20URL&input=text&text=Home%20Screen")
base64Encode(Value5)
@passcode
const ProvidedInput5 = prompt("Enter Passcode for {@APP}", "Number")
if ProvidedInput5 != @passcode {
stop()
}
}
rawAction("dk.simonbs.DataJar.SetValueIntent", {
"keyPath": "AppLocker.apps.{@APP}.lastUsed",
"overwriteStrategy": "alwaysAllow",
"valueConversionMode": "automatic",
"values": "@now"
})
openApp()
rawAction("dk.simonbs.DataJar.SetValueIntent", {
"keyPath": "AppLocker.lastApp",
"overwriteStrategy": "alwaysAllow",
"valueConversionMode": "text",
"values": "@APP"
})
Descompilado con cherri 2.3.0 (GPL-2.0). Puede que necesite pequeños ajustes antes de compilarse.
Valoraciones y reseñas
Escribe una reseña–
de 5
★★★★★
★★★★
★★★
★★
★
0 ratings
Aún no hay reseñas. ¡Sé el primero en compartir tu opinión!
Publicidad
También te puede gustar
Publicidad