//Fork and clone a repo to begin working on it

git clone <your-repo-name>
git remote add upstream <orchard-repo-name>
git remote set-url --push upstream noooooooo
git checkout -b DISTRO-1234
[do amazing work]
git add .
git status (git-reset any files you don't want to commit)
git commit -m "DISTRO-1234 Does Thing"
git push origin DISTRO-1234

//You have PR up, someone changes code, you need to incorporate that

git pull --rebase upstream master
git push -f origin DISTRO-1234
git push —force-with-lease

//Moving into a python environment

python3 -m venv env
source env/bin/activate OR . env/bin/activate
make pip_dev
make tests_unit
(Look at repos Makefile for other commands)


// Run only certain unit tests
yarn run test:unit -u src/components/track-builder/track-edit-form/__tests__/track-edit-form.spec.js

// Enable FF with PUT request
QA feature flag-enabling PUT request: https://qa-ows-features.theorchard.io/features/FEATURE_FLAG/user/alw:XXXXX

alw user ID XXXXX is person at label_name
you should be able to just search for label_name in OrchAdmin QA and
click Login as Admin (since person is the primary contact)
but occasionally that’s fussy, so to be safe I always open up the record
label page in OrchAdmin and click on her login which will open QA Workstation

JSON message body:
{"variant_name": "enabled"}

//Etc
print in php
echo message;
exit;


terraform init (once)
terraform plan
terraform apply

#  NEED TO RUN JERRY SCRIPT BEFORE TERRAFORM OR ZAPPA-ING
# cus you need fresh aws creds...to do aws things...

. env/bin/activate
zappa init
zappa deploy <env>


jcarrion aws-creds-generator script
go into directory
. env/bin/activate (you should already have python env with awscli installed)
. ./generate.sh

creds are stored in ~/.aws/.store (hidden file)
you should put your creds in ~/.aws/credentials so they can be found

if __name__ == '__main__':
    handler()

printenv

import ipdb; ipdb.set_trace()


To reset alarm state of QA Cloudwatch Alarm for UPC Provisioner SQS:

aws cloudwatch set-alarm-state --alarm-name qa-upc-provisioner-queue-depth-alarm --state-value OK --state-reason reset --region us-east-1

ctrl + R (reverse search in command line to find old commands you ran)

aws cloudwatch set-alarm-state --alarm-name qa-upc-provisioner-queue-depth-alarm --state-value OK --state-reason reset --region us-east-1
~
