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
| // split a file path into all the elements of the path | |
| func filePathElements(f string) []string { | |
| paths := make([]string, 0) | |
| fTemp := f | |
| lastElem := "" | |
| for fTemp != "" && fTemp != "/" { | |
| fTemp, lastElem = filepath.Split(filepath.Clean(fTemp)) | |
| paths = append([]string{lastElem}, paths...) | |
| } | |
| return paths |
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
| { | |
| "annotations": { | |
| "list": [ | |
| { | |
| "builtIn": 1, | |
| "datasource": "-- Grafana --", | |
| "enable": true, | |
| "hide": true, | |
| "iconColor": "rgba(0, 211, 255, 1)", | |
| "name": "Annotations & Alerts", |
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
| package main | |
| import ( | |
| "bytes" | |
| "encoding/json" | |
| "fmt" | |
| "log" | |
| "github.com/jinzhu/copier" | |
| ) |
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
| { | |
| "__inputs": [ | |
| { | |
| "name": "DS_EDGEX_INFLUX DATABASE", | |
| "label": "EdgeX Influx database", | |
| "description": "", | |
| "type": "datasource", | |
| "pluginId": "influxdb", | |
| "pluginName": "InfluxDB" | |
| } |
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
| # get the usb device's id/info (for me this was /dev/sda1) | |
| sudo blkid | |
| # unmount it if it's currently mounted | |
| sudo umount /dev/sda1 | |
| # make the device into swap space | |
| ################################################################################## | |
| #### CAUTION THIS WILL ERASE EVERYTHING ON THE DRIVE ####################### | |
| #### PLEASE ENSURE THIS IS THE CORRECT DRIVE AND THERE'S ####################### | |
| #### NOTHING OF VALUE ON THE USB DRIVE ####################### | |
| ################################################################################## |
NewerOlder