Google Apps脚本发布插件供内部使用 [英] Google Apps script publishing addon for internal use

查看:116
本文介绍了Google Apps脚本发布插件供内部使用的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如果它仅用于我的内部使用,是否可以在没有Google批准的情况下发布附加组件?如果不是,那么是否有可能让一些Google Apps脚本项目成为全球。因此,我不需要将相同的代码/功能复制到其他电子表格或文档,以使我的自定义宏再次运行。

您可以发布附加组件,以限制到特定的域名。



https://developers.google.com/apps-script/add-ons/publish



如果附件没有公开发布,那么它不会通过审批流程。

是的,有一种方法可以将一个项目中的代码全局化为其他项目。您可以通过在另一个项目中使用全局项目的项目键来实现这一点。它被称为图书馆。



如果您希望其他Google电子表格或文档的用户能够使用简单方式来使用您的代码,(或者您可以访问您自己的自己的代码从另一个文档中获得)给他们您的项目密钥,他们可以将您的代码作为库存取到他们的项目中。



<在资源下选择库。你不需要做任何事情来创建一个库。每个Apps Script项目都可以作为库来使用。您只需共享项目键。



您可以将一个附加菜单项添加到Google电子表格或文档中,而无需发布附加组件,并且该附加组件菜单项将运行 在该文档中的任何代码 ,就像附加组件一样。但是您需要编辑想要部署代码的每个用户的文档,并手动将代码添加到其文档中。



在Add-On菜单下创建菜单项没有意义,因为您可以创建自定义菜单。


Is it somehow possible to publish add-on without Google approval if it is going to be used for my internal use only?

If not, is there any possibility to make some of the Google Apps Script projects global. So that I would not need to copy same code/functionality to another spreadsheets or docs to get my custom macros to work again.

解决方案

You can publish an Add-On to be restricted to a specific domain.

https://developers.google.com/apps-script/add-ons/publish

If the Add-on is not being published publicly, then it does not go through the approval process.

Yes, there is a way to make code in one project "global" to other project. You do that by using the Project Key of the "global" project in another project. It's called a Library.

If you want an "easy" way for users of other Google Spreadsheets or Docs to be able to use your code, (Or for you to access your own code from another document your own) give them your Project Key, and they can access your code as a "Library" to their Project.

Under "Resources" choose, "Libraries". You don't need to do anything to create a Library. Every Apps Script project is available as a Library. All you do is share the Project Key.

You can add an "Add-On" menu item to a Google Spreadsheet or Doc, without publishing an Add-On, and that Add-On menu item will run any code that is in that document, just like an add on. But you would need to edit the document of every user you wanted to deploy the code to, and manually add the code to their document.

There's no point in creating a menu item under the Add-On menu, since you can create a custom menu.

这篇关于Google Apps脚本发布插件供内部使用的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆