Copy box link from applescript or bash script?
Some context: I used to use this workflow with dropbox, until dropbox got rid of public folders and broke this process.
http://destroytoday.com/writings/gif-workflow/
I've been trying to get it working with box and here's what I'm trying to accomplish. I have everything I need except in dropbox i was able to get the `basename`, the filename, and the url was always `https://dl.dropboxusercontent.com/u/`++>` but box is `https://acorio.box.com/s/`+>`
all I want is to be able to in a script, copy that box link value. Does anyone have any idea how to? I've been researching it for a while to no avail.
This is what I had working for dropbox in a .sh
dropbox_url="https://dl.dropboxusercontent.com/u//" echo ${dropbox_url}{query}
-
I would love to know this also as then I can use Hammerspoon to copy the link to the pasteboard for sending in chat. Even better would be a Screenshots directory and support in Box. This is as far as I've gotten. Might be possible to call into AppleScript to do some context menu clicking but ugh.
boxPath = os.getenv("HOME") .. "/Box" if hs.fs.displayName(boxPath) ~= nil then boxScreenshotsPath = boxPath .. "/Screenshots" if hs.fs.displayName(boxScreenshotsPath) == nil then os.execute("mkdir " .. boxScreenshotsPath) end hs.execute("defaults write com.apple.screencapture location " .. boxScreenshotsPath) function openScreenshots(files) hs.execute("open " .. boxScreenshotsPath) end hs.pathwatcher.new(boxScreenshotsPath, openScreenshots):start() end
Please sign in to leave a comment.
Comments
1 comment