以编程方式创建json文件的zc.buildout配方

nti.recipes.json的Python项目详细描述


nti.recipes.json

https://travis-ci.org/NextThought/nti.recipes.json.svg?branch=masterhttps://coveralls.io/repos/github/NextThought/nti.recipes.json/badge.svg?branch=master

这是一个zc.buildoutrecipe,它以编程方式创建json文件

让我们看一个使用构建部分的示例:

[nodeserver-env]
recipe = nti.recipes.json
output-file = /home/user/etc/nodeserver-env.json
contents-section = nodeserver-env-root

[nodeserver-env-root]
stripe-section = nodeserver-stripe
jquery-payment-section = nodeserver-jquery.payment

[nodeserver-jquery.payment]
requires =
  jquery
  stripe
  **end-list**
url = https://my.server.com/libs/jquery.payment/1.3.2/jquery.payment.min.js
definesSymbol = jQuery.payment

[nodeserver-stripe]
url = https://js.stripe.com/v2/
definesSymbol = Stripe

/home/user/etc/nodeserver-env.json的输出为:

{
    "jquery-payment": {
                "definesSymbol": "jQuery.payment",
                "requires": [
                        "jquery",
                        "stripe"
                ],
                "url": "https://my.server.com/libs/jquery.payment/1.3.2/jquery.payment.min.js"
        },
        "stripe": {
                "definesSymbol": "Stripe",
                "url": "https://js.stripe.com/v2/"
        }
}

更改

1.0.0(2018-02-19)

  • 第一个pypi版本。

欢迎加入QQ群-->: 979659372 Python中文网_新手群

推荐PyPI第三方库


热门话题
java如何使用MVC设计模式观察嵌套对象   java将多个客户端连接到服务器   合并Java Web应用程序   Spring Security中未捕获java AuthenticationSuccessEvent   java Firebase JSON到Arraylist内部的Arraylist,存在对象问题   在Java15的sealedclasses特性中,final类和非密封类之间有什么区别?   java我可以使用数组。copyOf制作二维数组的防御副本?   java球不会在屏幕上移动   Java类如何在同一个文件中包含两个类?   java使用“Character.isWhiteSpace”删除所有空白   java阻止在RealmList中保存时创建领域对象   如何仅在ConnectionFactory上使用Java JMS身份验证   spring可以强制java对象在运行时实现接口吗?   socket无法在JAVA中使用TCP启用双工模式通信