Last active
December 22, 2017 19:38
-
-
Save ilyapuchka/33204f88e78e90c8a0939398d54eeba6 to your computer and use it in GitHub Desktop.
Export to Paw automation script
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// First make sure that you have granted access to Automator, Xcode and Paw in accessibility section in Security & Privacy settings. | |
// Then create a new Service workflow in Automator with following actions: | |
1. Copy to clipboard | |
2. Launch Application: "Paw" | |
3. Run AppleScript: | |
tell application "System Events" | |
tell process "Paw" | |
click menu item "Text" of menu 1 of menu item "Import" of menu 1 of menu bar item "File" of menu bar 1 | |
tell application "System Events" to keystroke "v" using {command down} | |
click button "Import" of sheet 1 of window 1 | |
delay 1 | |
click button "Import" of sheet 1 of window 1 | |
delay 1 | |
click button "OK" of sheet 1 of window 1 | |
delay 1 | |
// this works in a empty project, but not in the project with groups of requests | |
// so you might need to remove it | |
select last row of outline 1 of scroll area 1 of splitter group 1 of splitter group 1 of window 1 | |
tell application "System Events" to keystroke return using {command down} | |
end tell | |
end tell | |
// Now you will be able to export your requests logs to Paw using Services from context menu just with one click. | |
// Make sure that logs are in one of the formats supported by import extensions you have installed in Paw (i.e. curl) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment