Skip to content

Instantly share code, notes, and snippets.

View jonsamp's full-sized avatar

Jon Samp jonsamp

View GitHub Profile
# Privacy Policy
This privacy policy governs your use of the software application QRU? (“Application”) for mobile devices that was created by Jon Samp. Please read this policy and our Mobile Terms and Conditions carefully; by using the App you confirm to have understood and agreed to them.
## What information does the Application obtain and how is it used?
### User Provided Information
The Application does not obtain the information you provide when you download and register the Application.
Builds, submissions, updates and more are all a part of delivering your app to users. Workflows consist of a sequence of jobs, which help you and your team get things done. You can do things like building your project, then submitting that build to the app stores. Since each job can have prerequisites and conditionals, you can automate you and your team’s release process.
## Create a workflow file
You can get started by creating a directory named **.eas/workflows** at the root of your project, then creating a **.yml** file inside of it. For example: **.eas/workflows/hello-world.yml**.
## Create a workflow
Each workflow consists of three top-level elements:
[
{
"key": "ctrl+x 1",
"command": "workbench.action.tasks.runTask",
"args": "test file"
},
{
"key": "ctrl+x 2",
"command": "workbench.action.tasks.runTask",
"args": "verify"
{
"version": "2.0.0",
"tasks": [
{
"label": "test file",
"type": "shell",
"command": "yarn test --watch ${relativeFile}",
"group": "test",
"presentation": {
"echo": true,
@jonsamp
jonsamp / update.yml
Last active July 28, 2021 15:35
EAS publish GitHub action
name: update
on:
push:
branches: [main]
jobs:
update:
name: EAS Update
runs-on: ubuntu-latest
steps:
const { spawnSync } = require('child_process');
// const packageJSON = require('./package.json');
// const modules = { ...packageJSON.dependencies, ...packageJSON.devDependencies };
// const allModuleNames = Object.keys(modules);
const fs = require('fs');
const path = require('path');

Privacy Policy

This privacy policy governs your use of the software application Gray One (“Application”) for mobile devices that was created by Jon Samp. Please read this policy and our Mobile Terms and Conditions carefully; by using the App you confirm to have understood and agreed to them.

What information does the Application obtain and how is it used?

User Provided Information

The Application does not obtain the information you provide when you download and register the Application.

const arguments = [...process.argv];
const actualMiles = arguments[2];
const date = arguments[3];
function dayOfYear() {
let now = new Date();
if (date) {
now = new Date(date);
}
const path = require('path');
const fs = require('fs');
let tsFiles = 0;
let jsFiles = 0;
let testFiles = 0;
let storyFiles = 0;
const listDir = (dir, fileList = []) => {
let files = fs.readdirSync(dir);
@jonsamp
jonsamp / rename-files.js
Last active December 25, 2019 18:17
Rename files recursively
const path = require('path');
const fs = require('fs');
const listDir = (dir, fileList = []) => {
let files = fs.readdirSync(dir);
files.forEach(file => {
if (fs.statSync(path.join(dir, file)).isDirectory()) {
fileList = listDir(path.join(dir, file), fileList);
} else {