mirror of
https://github.com/RfidResearchGroup/proxmark3.git
synced 2026-05-24 21:15:17 +00:00
Add examples to fetch prefs from Lua & Python scripts
This commit is contained in:
@@ -13,3 +13,15 @@ end
|
||||
|
||||
print("Device:", p.name)
|
||||
p:console("Rem passthru remark! :coffee:", true)
|
||||
|
||||
local json = require("dkjson")
|
||||
print("Fetching prefs:")
|
||||
p:console("prefs show --json")
|
||||
local prefs, err = json.decode(p.grabbed_output)
|
||||
if not prefs then
|
||||
print("Error decoding JSON: ", err)
|
||||
else
|
||||
print("Save path: ", prefs['file.default.savepath'])
|
||||
print("Dump path: ", prefs['file.default.dumppath'])
|
||||
print("Trace path:", prefs['file.default.tracepath'])
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user