Skip to content

Instantly share code, notes, and snippets.

View troyharvey's full-sized avatar
:octocat:

Troy Harvey troyharvey

:octocat:
View GitHub Profile
@troyharvey
troyharvey / my-git-workflow.md
Last active July 17, 2025 20:51
A brief description of how I like to use git

My git Workflow

This is just one way of using git/GitHub. But I have been using this same basic flow for 15 years and I rarely have trouble.

  1. Switch to the main branch

     git switch main
    
@troyharvey
troyharvey / ReEncryptDataCommand.php
Created September 18, 2019 19:26
Encrypt data after changing the APP_KEY
<?php
namespace App\Console\Commands;
use DB;
use Illuminate\Encryption\Encrypter;
use Illuminate\Support\Str;
use Illuminate\Console\Command;
class ReEncryptData extends Command
@troyharvey
troyharvey / README.md
Last active May 12, 2024 08:25
GitHub Action for running the getdbt.com dbt CLI with BigQuery

Using GitHub Actions to run dbt

This example shows you how to use GitHub Actions to run dbt against BigQuery.

  1. Follow the instructions on getdbt.com for installing and initializing a dbt project.

  2. Copy this action (dbt.yml) into the workflows directory.

     mkdir .github
     mkdir .github/workflows
    

cp ~/Downloads/dbt.yml .github/workflows/

@troyharvey
troyharvey / README.md
Created May 29, 2020 03:17
Transform the opawg Podcast User Agent list into a jsonl file for BigQuery
  1. Generate a jsonl file with all the Podcast User Agents.

     node agents.js
    
  2. Use the BigQuery console to create a table and load the podcast-user-agents.jsonl file into the new table.

@troyharvey
troyharvey / direnv.md
Created June 28, 2022 23:06
Automatically load .env files