- Download firmware (70.03.0A) to the internal smartphone memory or SD card;
- Install nRF Toolbox for BLE from Google Play;
- Open nRF Toolbox → go to DFU section;
- Select firmware file → chose "application" type with "no init packet";
- Select device for firmware upload (named "DfuMode");
- Tap "Start".
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
var asyncHook = require('async-hook'); | |
var path = require('path'); | |
var utils = require('../../public/src/utils'); | |
function CLS() { | |
var mem = {}; | |
var self = this; | |
this.storage = null; |
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
// this file is assumed to be in the root NodeBB directory | |
var continuationLocalStorage = require('continuation-local-storage'); | |
var cls = continuationLocalStorage.createNamespace('test'); | |
var async = require('async'); | |
var path = require('path'); | |
var nconf = require('nconf'); |
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
var path = require('path'); | |
var nconf = require('nconf'); | |
var async = require('async'); | |
nconf.file({ file: path.join(__dirname, './config.json') }); | |
var db = require('./src/database'); | |
var S3_BASE_URL = 'https://nodebb-assests.s3-us-west-2.amazonaws.com/'; |
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
function promiseWhile (condition, execute) { | |
return new Promise(function(resolve, reject) { | |
var iterate = function () { | |
if (condition()) { | |
return execute() | |
.then(iterate) | |
.catch(reject); | |
} | |
return resolve(); |
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
var path = require('path'); | |
var nconf = require('nconf'); | |
var async = require('async'); | |
nconf.file({ file: path.join(__dirname, './config.json') }); | |
var dbType = nconf.get('database'); | |
var productionDbConfig = nconf.get(dbType); | |
nconf.set(dbType, productionDbConfig); |
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
var path = require('path'); | |
var nconf = require('nconf'); | |
var async = require('async'); | |
var url = require('url'); | |
var _convert = require('./node_modules/nodebb-plugin-import/node_modules/bbcode-to-markdown'); | |
nconf.file({ file: path.join(__dirname, './config.json') }); | |
var dbType = nconf.get('database'); |
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
// tested with NodeBB v1.4.6+ | |
var path = require('path'); | |
var nconf = require('nconf'); | |
var async = require('async'); | |
var pkg = require('./package.json'); | |
nconf.file({ file: path.join(__dirname, './config.json') }); |
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
// tested with NodeBB v1.4.6+ | |
var path = require('path'); | |
var url = require('url'); | |
var nconf = require('nconf'); | |
var async = require('async'); | |
var pkg = require('./package.json'); | |
nconf.file({ file: path.join(__dirname, './config.json') }); |
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/sh | |
wget http://dev.mysql.com/get/Downloads/MySQL-5.7/mysql-5.7.20-macos10.12-x86_64.tar.gz | |
tar xfvz mysql-5.7* | |
echo "stopping mamp" | |
sudo /Applications/MAMP/bin/stop.sh | |
sudo killall httpd mysqld | |
echo "creating backup" |