This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
_ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ | |
_| |_ |_| _| |_ |_| _| |_ |_| _| |_ |_| _| |_ |_| _| | |
| _ |✨“Would you tell me, please,|_ _| _ | _ | _ |_ | |
|_| |_| | |___| |___| | |_| |_| | |___| |___| | |_| |_| | |___| | |
_ _ | __which way I ought to go from here?" _ ✨_ | ___ | |
| |_| | |_| _| |_ |_| | |_| | _| |_ _| |_ | |_| | |_| _| | |
|_ _| _ "That depends a good deal | | _ | |_ _| _ |_ | |
_| |___| |___| |___| |___| |_ |_| |_| |_| |_| _| |___| |___| | |
| ___ ___ ✨_ ___on where you want to get to." ___ ___ | |
|_| _| |_ |_| |_| _| |_ |_| | |_| | | |_| | _| |_ |_| _| |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Walker { | |
int x; | |
int y; | |
Walker () { | |
x = width / 2; | |
y = height / 2; | |
} | |
void display() { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import java.util.Random; | |
Random generator; | |
void setup() { | |
size(1120,1200); | |
generator = new Random(); | |
background(50); | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function postTopicNamesResponse(channel, topicNames) { | |
var payload = { | |
"channel": "#" + channel, | |
"username": "Topic List", | |
"icon_emoji": ":grin:", | |
"attachments":[ | |
{ | |
"fallback": "This is an update from a Slackbot integrated into your organization. Your client chose not to show the attachment.", | |
"pretext": "You can use the following topic names: " + topicNames.join(", "), | |
"mrkdwn_in": ["pretext"] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function testNewItemPost() { | |
var request = { | |
parameters: { | |
token: "[]", | |
user_name: "michelle", | |
text: "add: Rural America; Hillbilly Elegy; J.D. Vance; From a former marine and Yale Law School graduate, a powerful account of growing up in a poor Rust Belt town that offers a broader, probing look at the struggles of America’s white working class; https://www.amazon.com/gp/product/0062300547/ref=pd_bxgy_14_2?ie=UTF8&pd_rd_i=0062300547&pd_rd_r=MG2AV2PZZVEXNYZ1Y84V&pd_rd_w=xCKNl&pd_rd_wg=55Iya&psc=1&refRID=MG2AV2PZZVEXNYZ1Y84V;" | |
} | |
}; | |
doPost(request); | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function postResponse(channel, userName, topic, title, author, description, link) { | |
var payload = { | |
"channel": "#" + channel, | |
"username": "New item added to reading list", | |
"icon_emoji": ":grin:", | |
"link_names": 1, | |
"attachments":[ | |
{ | |
"fallback": "This is an update from a Slackbot integrated into your organization. Your client chose not to show the attachment.", |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function addNewItemToSheet(sheets, params) { | |
// PROCESS TEXT FROM MESSAGE | |
var textRaw = String(params.text).replace(/^\s*add\s*:*\s*/gi,''); | |
var text = textRaw.split(/\s*;\s*/g); | |
// FALL BACK TO DEFAULT TEXT IF NO UPDATE PROVIDED | |
var sheetName = text[0] || ""; | |
var title = text[1] || ""; | |
var author = text[2] || ""; | |
var description = text[3] || ""; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function doPost(request) { | |
var params = request.parameters; | |
// Make sure that the request came from our slack integration. | |
if (params.token == "[OUTGOING WEBHOOK TOKEN]") { | |
// Get the spreadsheet | |
var sheets = SpreadsheetApp.openById('[YOUR SPREADSHEET ID]'); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function doPost(request) { | |
var params = request.parameters; | |
// Get the spreadsheet | |
var sheets = SpreadsheetApp.openById('[YOUR SPREADSHEET ID]'); | |
} |
NewerOlder