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
| // Changes XML to JSON | |
| // Modified version from here: http://davidwalsh.name/convert-xml-json | |
| function xmlToJson(xml) { | |
| // Create the return object | |
| var obj = {}; | |
| if (xml.nodeType == 1) { // element | |
| // do attributes | |
| if (xml.attributes.length > 0) { |
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
| from gmusicapi import Webclient | |
| from gmusicapi import Mobileclient | |
| import vlc | |
| import urllib | |
| # Use Google account credintials. If two factor is enabled, use application specific password. | |
| email = '[email protected]' | |
| password = 'password' | |
| # Device ID for API queries. Leave blank if unknown. |
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
| #!/bin/bash | |
| # this will find all node_modules above your path and will remove them | |
| find . | grep /node_modules$ | grep -v /node_modules/ | xargs rm -fR |
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
| using Discord; | |
| using Discord.Commands; | |
| using System; | |
| using System.Collections.Generic; | |
| using System.Linq; | |
| using System.Text; | |
| using System.Threading.Tasks; |
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
| using Discord; | |
| using Discord.Commands; | |
| using System; | |
| using System.Collections.Generic; | |
| using System.Linq; | |
| using System.Text; | |
| using System.Threading.Tasks; |
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
| // Load up the discord.js library | |
| const Discord = require("discord.js"); | |
| // This is your client. Some people call it `bot`, some people call it `self`, | |
| // some might call it `cootchie`. Either way, when you see `client.something`, or `bot.something`, | |
| // this is what we're refering to. Your client. | |
| const client = new Discord.Client(); | |
| // Here we load the config.json file that contains our token and our prefix values. | |
| const config = require("./config.json"); |
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 doGet(){ | |
| var ss = SpreadsheetApp.openById("//key ommitted"); | |
| return exportJSON(ss); | |
| } | |
| // Exports current sheet as JSON and displays in message box. | |
| function exportJSON(ss) { | |
| var sheet = ss.getSheetByName("sessions"); | |
| var rowsData = getRowsData(sheet); |
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
| /** | |
| * Adds a custom menu to the active spreadsheet, containing a single menu item | |
| * for invoking the exportJSON() function specified above. | |
| * The onOpen() function, when defined, is automatically invoked whenever the | |
| * spreadsheet is opened. | |
| * For more information on using the Spreadsheet API, see | |
| * https://developers.google.com/apps-script/service_spreadsheet | |
| */ | |
| function onOpen() { | |
| var sheet = SpreadsheetApp.getActiveSpreadsheet(); |
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
| Windows Registry Editor Version 5.00 | |
| ; | |
| ; Adds 'Open in Atom' to context menu (when you right click) in Windows Explorer. | |
| ; | |
| ; Based on https://github.com/Zren/atom-windows-context-menu. It didn't work | |
| ; https://github.com/Zren/atom-windows-context-menu/issues/1. | |
| ; | |
| ; Save this file to disk with a .reg extension. Replace C:\\Atom\\atom.exe with | |
| ; the path to the atom executable on your machine. |
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
| static toDictionary<TItem>( | |
| array: TItem[], | |
| getKey: (item: TItem) => number): { [id: number]: TItem }; | |
| static toDictionary<TItem, TValue>( | |
| array: TItem[], | |
| getKey: (item: TItem) => number, | |
| getValue: (item: TItem) => TValue): { [id: number]: TValue }; | |
| static toDictionary<TItem>( | |
| array: TItem[], | |
| getKey: (item: TItem) => string): { [id: string]: TItem }; |
NewerOlder