Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

webhook-templates

Package Overview
Dependencies
Maintainers
1
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

webhook-templates - npm Package Compare versions

Comparing version 0.1.3 to 0.1.4

9

lib/webhook-templates.js

@@ -1,2 +0,2 @@

// Generated Fri, 25 May 2012 14:40:56 GMT
// Generated Sat, 07 Jul 2012 12:39:59 GMT
Template = require('./template');

@@ -18,2 +18,7 @@ dust = Template.Dust

templateStrings["github"] = "{!WebhookTemplate{\n \"name\" : \"GitHub\"\n, \"author\" : \"Benjie Gillam (http://www.benjiegillam.com/)\"\n, \"format\" : \"JSON\"\n, \"jsonfield\" : \"payload\"\n, \"url\" : \"http://help.github.com/post-receive-hooks/\"\n}!}\n**{#last array=commits}{author.name}{/first}**{~s}\npushed to **{#gitbranch ref=ref/}**{~s}\nof{~s}**\n{?repository.url}\n [{repository.owner.name}/{repository.name}]({repository.url})\n{:else}\n {repository.name}\n{/repository.url}**\n{?commits}\n :\n {#reverse array=commits}\n {~n}{~s}{~s}- {#gitshortmessage message=message/}{~s}\n {?url}\n ([{#gitshorthash hash=id/}]({url}))\n {:else}\n ({#gitshorthash hash=id/})\n {/url}\n {/reverse}\n{/commits}\n";
(function(){dust.register("github",body_0);function body_0(chk,ctx){return chk.write("**").section(ctx.get("last"),ctx,{"block":body_1},{"array":ctx.get("commits")}).write("** pushed to **").section(ctx.get("gitbranch"),ctx,{},{"ref":ctx.get("ref")}).write("** of **").exists(ctx.getPath(false,["repository","url"]),ctx,{"else":body_2,"block":body_3},null).write("**").exists(ctx.get("commits"),ctx,{"block":body_4},null);}function body_1(chk,ctx){return chk.reference(ctx.getPath(false,["author","name"]),ctx,"h");}function body_2(chk,ctx){return chk.reference(ctx.getPath(false,["repository","name"]),ctx,"h");}function body_3(chk,ctx){return chk.write("[").reference(ctx.getPath(false,["repository","owner","name"]),ctx,"h").write("/").reference(ctx.getPath(false,["repository","name"]),ctx,"h").write("](").reference(ctx.getPath(false,["repository","url"]),ctx,"h").write(")");}function body_4(chk,ctx){return chk.write(":").section(ctx.get("reverse"),ctx,{"block":body_5},{"array":ctx.get("commits")});}function body_5(chk,ctx){return chk.write("\n - ").section(ctx.get("gitshortmessage"),ctx,{},{"message":ctx.get("message")}).write(" ").exists(ctx.get("url"),ctx,{"else":body_6,"block":body_7},null);}function body_6(chk,ctx){return chk.write("(").section(ctx.get("gitshorthash"),ctx,{},{"hash":ctx.get("id")}).write(")");}function body_7(chk,ctx){return chk.write("([").section(ctx.get("gitshorthash"),ctx,{},{"hash":ctx.get("id")}).write("](").reference(ctx.get("url"),ctx,"h").write("))");}return body_0;})();
(function(){dust.register("github",body_0);function body_0(chk,ctx){return chk.write("**").section(ctx.get("last"),ctx,{"block":body_1},{"array":ctx.get("commits")}).write("** pushed to **").section(ctx.get("gitbranch"),ctx,{},{"ref":ctx.get("ref")}).write("** of **").exists(ctx.getPath(false,["repository","url"]),ctx,{"else":body_2,"block":body_3},null).write("**").exists(ctx.get("commits"),ctx,{"block":body_4},null);}function body_1(chk,ctx){return chk.reference(ctx.getPath(false,["author","name"]),ctx,"h");}function body_2(chk,ctx){return chk.reference(ctx.getPath(false,["repository","name"]),ctx,"h");}function body_3(chk,ctx){return chk.write("[").reference(ctx.getPath(false,["repository","owner","name"]),ctx,"h").write("/").reference(ctx.getPath(false,["repository","name"]),ctx,"h").write("](").reference(ctx.getPath(false,["repository","url"]),ctx,"h").write(")");}function body_4(chk,ctx){return chk.write(":").section(ctx.get("reverse"),ctx,{"block":body_5},{"array":ctx.get("commits")});}function body_5(chk,ctx){return chk.write("\n - ").section(ctx.get("gitshortmessage"),ctx,{},{"message":ctx.get("message")}).write(" ").exists(ctx.get("url"),ctx,{"else":body_6,"block":body_7},null);}function body_6(chk,ctx){return chk.write("(").section(ctx.get("gitshorthash"),ctx,{},{"hash":ctx.get("id")}).write(")");}function body_7(chk,ctx){return chk.write("([").section(ctx.get("gitshorthash"),ctx,{},{"hash":ctx.get("id")}).write("](").reference(ctx.get("url"),ctx,"h").write("))");}return body_0;})();
templateNames.push("kickofflabs");
templateDetails["kickofflabs"] = {"name":"KickoffLabs","author":"Benjie Gillam (http://www.benjiegillam.com/)","format":"form","url":"http://help.github.com/post-receive-hooks/"};
templateStrings["kickofflabs"] = "{!WebhookTemplate{\n \"name\" : \"KickoffLabs\"\n, \"author\" : \"Benjie Gillam (http://www.benjiegillam.com/)\"\n, \"format\" : \"form\"\n, \"url\" : \"http://help.github.com/post-receive-hooks/\"\n}!}\n*{action}* from *[{url}]({url})*: **[{email}](mailto:{email})**\n";
(function(){dust.register("kickofflabs",body_0);function body_0(chk,ctx){return chk.write("*").reference(ctx.get("action"),ctx,"h").write("* from *[").reference(ctx.get("url"),ctx,"h").write("](").reference(ctx.get("url"),ctx,"h").write(")*: **[").reference(ctx.get("email"),ctx,"h").write("](mailto:").reference(ctx.get("email"),ctx,"h").write(")**");}return body_0;})();
{
"name": "webhook-templates",
"version": "0.1.3",
"version": "0.1.4",
"description": "Dust.js templates for webhook payloads",

@@ -5,0 +5,0 @@ "keywords": ["pim", "webhook", "templates", "dust", "dustjs"],

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc