This file contains hidden or 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
#Download and install raspbian-lite | |
#Expand filesystem | |
sudo raspi-config | |
expand filesystem | |
sudo reboot | |
#Test new space | |
df -H |
This file contains hidden or 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 five = require("johnny-five") | |
const client = require('messenger').createSpeaker(8000) | |
const stopwatch = require('../stopwatch') | |
let board, buttons, timer | |
board = new five.Board({ | |
repl: false | |
}) | |
const buttonsObj = { |
This file contains hidden or 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
{"lastUpload":"2020-08-25T14:55:45.150Z","extensionVersion":"v3.4.3"} |
This file contains hidden or 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
{"lastUpload":"2018-09-22T20:34:19.139Z","extensionVersion":"v3.1.2"} |
This file contains hidden or 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
class Band { | |
id: string; | |
name: string; | |
formationYear: number; | |
genres: Array<string>; | |
} |
This file contains hidden or 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
import { Collection } from 'fireorm'; | |
@Collection() | |
class Band { | |
id: string; | |
name: string; | |
formationYear: number; | |
genres: Array<string>; | |
} |
This file contains hidden or 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
import * as admin from 'firebase-admin'; | |
const serviceAccount = require('../firestore.creds.json'); | |
admin.initializeApp({ | |
credential: admin.credential.cert(serviceAccount), | |
databaseURL: `https://${serviceAccount.project_id}.firebaseio.com`, | |
}); | |
const firestore = admin.firestore(); |
This file contains hidden or 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
import Band from './models/Band' | |
import { getRepository } from 'fireorm' | |
const bandRepository = getRepository(Band, firestore); | |
// Create a band | |
const band = new Band(); | |
band.name = "A Perfect Circle"; | |
band.formationYear = 1999; | |
band.genres = ['alternative-rock', 'hard-rock'] |
This file contains hidden or 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
import { Collection, SubCollection, ISubCollection } from 'fireorm'; | |
class Album { | |
id: string; | |
name: string; | |
year: number; | |
} | |
@Collection() | |
export class Band { |
This file contains hidden or 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
import { getRepository } from 'fireorm'; | |
import Band from './models/Band'; | |
const bandRepository = getRepository(Band); | |
const band = await bandRepository.findById('red-hot-chili-peppers'); | |
const albumsAfter2000 = await band.albums.whereGreaterOrEqualThan('year', 2000).find(); |
OlderNewer