问题
I had published a private addon on google spreadsheet. However, the problem is, I lost the app script source code for my addon. I need to make some changes and publish it again.
How can I possibly get/download the code from the spreadsheet addon that I published on the chrome web-store?
I tried looking on https://chrome.google.com/webstore/developer/dashboard where there is a list of all my addons published but there's no option for reading the source code. A quick google search reveals nothing regarding this. Any suggestions?
回答1:
I figured out a way to find the code.
From your developer dashboard: https://chrome.google.com/webstore/developer/dashboard
click on more info
and then click to download the main.crx
file for the addon you're interested in.
main.crx
is a zip file which you should be able to unzip. On linux or mac you can do it from the command line unzip yourfilename_main.crx
open up manifest.json
and look for "container_id" the string after that is the file ID of your script.
https://script.google.com/d/container_id_of_your_script_here/edit
回答2:
It's not possible to get the source code from the Chrome Web Store. Instead you have to find the file that holds your Google Apps Script project. Take a look to the Trash of your Google Drive. For further details see Find or recover a file - Google Drive Help
来源:https://stackoverflow.com/questions/37806779/get-code-from-my-google-spreadsheet-addon-after-publishing