This file contains 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
const { BetaAnalyticsDataClient } = require("@google-analytics/data"); | |
const credentials = require("./sa1.json"); | |
const fs = require("fs"); | |
const propertyId = "301145746"; | |
// console.log(credentials); | |
const numberWithCommas = (x) => { | |
try { |
Magic words:
psql -U postgres
Some interesting flags (to see all, use -h
or --help
depending on your psql version):
-E
: will describe the underlaying queries of the\
commands (cool for learning!)-l
: psql will list all databases and then exit (useful if the user you connect with doesn't has a default database, like at AWS RDS)
This file contains 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 | |
#usage: | |
#arg1: directory where you want to save the specific sub dir from repo | |
#arg2: the repo clone url | |
#arg3: name of the specific directory | |
#ex: ./getGitDir.sh <outputdir> <cloneurl> <targetdir> | |
#get no of args passed | |
TOTALARGS="$#" | |
if [[ $TOTALARGS -lt 3 ]]; then |