These utilities are grouped into related files, for simpler copy & paste to your scripts.
A couple of helper functions to convert to & from A1 notation.
| # | |
| # Licensed to the Apache Software Foundation (ASF) under one | |
| # or more contributor license agreements. See the NOTICE file | |
| # distributed with this work for additional information | |
| # regarding copyright ownership. The ASF licenses this file | |
| # to you under the Apache License, Version 2.0 (the | |
| # "License"); you may not use this file except in compliance | |
| # with the License. You may obtain a copy of the License at | |
| # | |
| # http://www.apache.org/licenses/LICENSE-2.0 |
| id: foreach | |
| version: '1.0' | |
| specVersion: '0.8.0' | |
| name: foreach | |
| description: foreach flow | |
| functions: | |
| - name: printMessage | |
| type: custom | |
| operation: sysout | |
| start: ForEachState |
| { | |
| "id": "jsongreet", | |
| "version": "1.0", | |
| "specVersion": "0.8", | |
| "name": "Greeting workflow", | |
| "description": "JSON based greeting workflow", | |
| "start": "ChooseOnLanguage", | |
| "functions": [ | |
| { | |
| "name": "greetFunction", |
| 'use strict'; | |
| //SETTINGS | |
| const commentsServiceUrl="https://www.example.com/comments"; | |
| /** | |
| * remove html from a text | |
| * | |
| * @param {string} text the text to clean |
| CmdUtils.makeSearchCommand({ | |
| name: "mdn", | |
| url: "https://developer.mozilla.org/en-US/search?q={QUERY}", | |
| author: {name:"Fabrizio Antonangeli", email:"fabrizio.antonangeli@gmail.com"}, | |
| homepage:"http://developer.mozilla.org/", | |
| icon:"https://developer.cdn.mozilla.net/static/img/opengraph-logo.dc4e08e2f6af.png", | |
| description:"Mozilla Developer Network", | |
| parser: { | |
| container: ".result-list-item", | |
| title: " h4 a", |
| CmdUtils.makeSearchCommand({ | |
| name: "WordReference", | |
| url: "http://www.wordreference.com/redirect/translation.aspx?w={QUERY}", | |
| author: {name:"Fabrizio Antonangeli", email:"fabrizio.antonangeli@gmail.com"}, | |
| homepage:"http://wordreference.com/", | |
| icon:"http://www.wordreference.com/favicon.ico", | |
| description:"WordReference translator", | |
| parser: { | |
| container: ".WRD tr[id]", | |
| title: ".FrWrd strong", |