Skip to content

Instantly share code, notes, and snippets.

View gist:daf15db182dfbe8e9a5bc22decf0a5e5
var added = new Notification(notification).addedLabel(/Subtask.*/i);
if(parts = /Subtask(.*)/i.exec(added.name()))
{
if(!(listname = parts[1].trim()))
listname = "Checklist";
added.card().checklist(listname).items().each(function(item)
{
item.setName(
View gist:cdf9c804fda763da7ce0482c7b467ec9
var created = new Notification(notification).createdCard();
var list_name_to_clear = "PUT YOUR LIST NAME HERE";
if(!created.name() == "DELETE EMPTY DESCRIPTIONS")
throw new InvalidActionException("Not interested in created cards that don't tell us to delete descriptions");
created.board().cards().each(function(card)
{
if(!card.description().trim())
card.archive();
View gist:39997991a90cfbd1b5ac390bbb6d9331
var created = new Notification(notification).createdCard();
var list_name_to_clear = "PUT YOUR LIST NAME HERE";
if(!created.name() == "DELETE EMPTY DESCRIPTIONS")
throw new InvalidActionException("Not interested in created cards that don't tell us to delete descriptions");
created.board().list(list_name_to_clear).cards().each(function(card)
{
if(!card.description().trim())
card.archive();
View gist:39b2d93a336b90378ccce9330762310f
var board_name = "YOUR BOARD NAME";
var list_name = "YOUR LIST NAME";
//DON'T EDIT BELOW HERE
new Trellinator().board(board_name).list(list_name).cards().each(function(card)
{
if(!card.description().trim())
{
card.archive();
View gist:128845f23432666107d0cf2d707a52d8
var source_board_name = "ADD THE NAME HERE";
var target_board_name = "ADD THE NAME HERE";
////////////////////////
//don't edit below here
////////////////////////
var trell = new Trellinator();
var target_board = trell.board(target_board_name);
TrelloApi.searchCardsInBoards(trell.board(source_board_name),"is:archived edited:day").each(function(card)
View gist:efd0278b35b3fc705c92c3ed540ef55c
new Notification(notification).createdCard().postComment("Hello world!");
View gist:20c9476c2b7ce503767fec617ac241bb
var notif = new Notification(notification);
//when an item is added to checklist "Action Items"
var added = notif.addedChecklistItem();
if(added.checklist().name() != "Action Items")
throw new InvalidActionException("Don't act unless added to Action Items");
//convert the item to a linked card at the top of list "Inbox PlaceHolder"
var created = Card.create(
added.checklist().card().board().findOrCreateList(/Inbox Placeholder/i),
View gist:f2ff4386500fd833f159f14f30fc25bc
var notif = new Notification(notification);
notif.addedChecklist().setPosition("top");
View gist:dcaa9d432bd5b7fbb6800bd16afa0a59
var moved = new Notification(notification).movedCard();
var minutesum = 0;
var secondsum = 0;
var curlist = moved.currentList();
curlist.cards().each(function(card)
{
var timesplit = card.customFieldValue("Time").split(":");
if(timesplit.length > 1)
View gist:1bb36e02e9a1d0cda878024a26e6dd2e
var board = new Trellinator().board("YOUR BOARD NAME");
var youremail = "ADD YOUR EMAIL HERE";
///DO NOT EDIT BELOW HERE
var boardmembers = board.members().find(function(member)
{
return member.name();
}).asArray().join("\n");
var list = Card
.create(board.lists().first(),"ALL MEMBERS LIST")