Skip to content

Instantly share code, notes, and snippets.

View chase2981's full-sized avatar

Chase Gibbons chase2981

View GitHub Profile
@chase2981
chase2981 / forever-config.json
Created June 7, 2021 01:27 — forked from mrister/forever-config.json
Forever example with config file
{
// Sample configuration for app in /home/myuser/app dir
"uid": "app",
"max": 5, // restart the app successively maximum of 5 times
"spinSleepTime": 1000, // time to wait until a next restart is attempted (in ms)
"append": true, // append the logs, do not overwrite
"watch": true, // watch for changes and restart if they occur
"script": "server.js", // main startup script (almost like issuing node server.js)
"sourceDir": "/home/myuser/app", // the dir where your entire app code resides (dir structure is recursively traversed)
"args": ["--myAPIKey", "xBlzdn84fa"] // pass any arguments to your app
@chase2981
chase2981 / rxjs-diagrams.md
Created April 13, 2021 18:44 — forked from PCreations/rxjs-diagrams.md
Super Intuitive Interactive Diagrams to learn combining RxJS sequences by Max NgWizard K
@chase2981
chase2981 / docusaurus-copy-button.md
Created February 26, 2021 02:54 — forked from yangshun/docusaurus-copy-button.md
How to add the "Copy" button to code blocks in Docusaurus

Adding "Copy" (to Clipboard) Button

If you would like to add a button to your fenced code blocks so that users may copy the code, you can do so in Docusaurus. You will have to add some code to your Docusaurus project, as seen below.

Under static/js, create a file called code-block-buttons.js with the following:

// Turn off ESLint for this file because it's sent down to users as-is.
/* eslint-disable */
window.addEventListener('load', function() {
// task
// snake case
var taskJson = {
// this shows up in flex on the task as the primary text
"name": "(435) 999-5175",
// this is needed cuz there's no good way to access it on a task basis within the workflow expressions
"channelType": "chat",
// differentiates between different task queues based on acceptable response times
"type": "short-lived",
// this means it's an important task
@chase2981
chase2981 / rdBaseTaskRouterTaskAttributes.js
Last active February 9, 2021 23:16
Omnichannel Task Router Base Attributes
// task
// snake case
var taskJson = {
// this shows up in flex on the task as the primary text
"name": "[email protected]",
// differentiates between different task queues based on acceptable response times
"type": "short-lived",
"rd": {
// contactCenter -- we might not need this tbh -- especially if we do different flex projects or even different workspaces or workflows per contact center
"contact_center_id":1,
@chase2981
chase2981 / README.md
Last active December 7, 2020 01:39
RD Flex Style Guide Issues To Be Voted On

RD Flex Style Guide Issues To Be Voted On

Feel free to add to this as you see fit and make suggestions, I think anyone can commit to this gist if I'm not mistaken, or at very least quote it and comment on it.

This is still a work-in-progress. I plan to provide brief pros/cons foreach item in the final variation, as well as organize things a little better into common sections.

Right now I'm thinking we will just vote on these issues using a plain old google form, that way I know we will be able to reference the results within our documentation, but even our voting mechanism is up for debate at this point.

{
"Africa/Abidjan": "+00:00",
"Africa/Accra": "+00:00",
"Africa/Addis_Ababa": "+03:00",
"Africa/Algiers": "+01:00",
"Africa/Asmara": "+03:00",
"Africa/Asmera": "+03:00",
"Africa/Bamako": "+00:00",
"Africa/Bangui": "+01:00",
"Africa/Banjul": "+00:00",
@chase2981
chase2981 / wifiscanner.py
Created November 4, 2020 04:23 — forked from dropmeaword/wifiscanner.py
A simple python script which records and logs wifi probe requests.
#########################################################################
# Wifiscanner.py - A simple python script which records and logs wifi probe requests.
# Author - D4rKP01s0n
# Requirements - Scapy and Datetime
# Inspiration - Tim Tomes (LaNMaSteR53)'s WUDS https://bitbucket.org/LaNMaSteR53/wuds/
# Reminder - Change mon0 (around line 65) to your monitor-mode enabled wifi interface
#########################################################################
from datetime import datetime
@chase2981
chase2981 / SupervisorTaskCanvasComponent.tsx
Created April 5, 2020 05:27
Twilio Flex MessagingCanvas Examples
import * as React from "react";
import {
Manager, Actions, MessagingCanvas, MessagingCanvasContext, DynamicComponent, ContextProvider, MessageList, StateHelper, TaskHelper, ITask,
Supervisor,
TaskChannelDefinition,
TaskContextProps,
Theme
} from '@twilio/flex-ui';
import CoreApiService from '../Shared/CoreApiService';
import { Channel } from 'twilio-chat/lib/channel';