How to interface with a Stream Deck device.
The device uses the HID protocol to communicate with its software.
// First, run a Chrome instance on your Mac: | |
// /Applications/Google\ Chrome.app/Contents/MacOS/Google\ Chrome --remote-debugging-port=9222 &> /dev/null &; disown | |
const puppeteer = require('puppeteer-core'); | |
const axios = require('axios'); | |
const getBrowserWSEndpoint = async (baseUrl) => { | |
const response = await axios.get(`http://${baseUrl}/json/version`); | |
return response.data.webSocketDebuggerUrl; |
// helper to find Brave in User Agent string | |
function isBraveAgent(userAgentResponse) { | |
var isBraveIndex = ~userAgentResponse.indexOf('Brave') | |
if (isBraveIndex < 0) { | |
return true | |
} | |
return false | |
} | |
// Function from Javarome |
<template> | |
<canvas class="gridCanvas" | |
:width="width" | |
:height="height" | |
></canvas> | |
</template> | |
<script> | |
export default { | |
name: 'xon-GridCanvas', |
package main | |
import ( | |
"bytes" | |
"fmt" | |
"io" | |
"log" | |
"mime/multipart" | |
"net/http" | |
"os" |
#!/bin/bash | |
# 用于创建macOS安装ISO的脚本文件 | |
# 初始脚本来源:http://www.insanelymac.com/forum/topic/308533-how-to-create-a-bootable-el-capitan-iso-fo-vmware/ | |
set -x | |
SCRIPT_PATH=`pwd`/$0 | |
DMG_PATH="/Applications/Install macOS High Sierra.app/Contents/SharedSupport" |
# Description: Boxstarter Script | |
# Author: Jess Frazelle <[email protected]> | |
# Last Updated: 2017-09-11 | |
# | |
# Install boxstarter: | |
# . { iwr -useb http://boxstarter.org/bootstrapper.ps1 } | iex; get-boxstarter -Force | |
# | |
# You might need to set: Set-ExecutionPolicy RemoteSigned | |
# | |
# Run this boxstarter by calling the following from an **elevated** command-prompt: |
Short how-to for creating a reverse ssh tunnel to a remote server. Useful for breaking NATted connection for example.
opkg update
opkg install sshtunnel
<?php | |
// Note: $this->server is a "logged in" PHRETS $session | |
public function getLookupValues($resourceName, $className) | |
{ | |
$results = array(); | |
// Get Table Metadata for this resource/class | |
$tableMeta = $this->server->GetTableMetadata($resourceName, $className); |
#!/bin/bash | |
### Google Domains provides an API to update a DNS "Syntheitc record". This script | |
### updates a record with the script-runner's public IP, as resolved using a DNS | |
### lookup. | |
### | |
### Google Dynamic DNS: https://support.google.com/domains/answer/6147083 | |
### Synthetic Records: https://support.google.com/domains/answer/6069273 | |
USERNAME="" |