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
#!/usr/bin/env bash | |
function pass { | |
echo -e "\033[0;32m[OK]\033[0m ${1}" | |
} | |
function fail { | |
echo -e "\033[0;31m[ERROR]\033[0m ${1}" | |
} |
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
--- | |
Language: Cpp | |
# @see https://clang.llvm.org/docs/ClangFormatStyleOptions.html | |
# BasedOnStyle: Mozilla | |
AccessModifierOffset: -2 | |
AlignAfterOpenBracket: Align | |
AlignConsecutiveMacros: false | |
AlignConsecutiveAssignments: false | |
AlignConsecutiveDeclarations: false | |
AlignEscapedNewlines: Right |
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 | |
## performs two calls to /analyse for a given session and compares responses. | |
## If both match the test passes. | |
## If a mismatch occurs or a single response is invalid then the error and the response will be logged into ./error.log | |
## Tests are repeated 50 times. | |
# config | |
# - a valid seesion id, the session has to be finished (all questions answered) | |
SESSID=<SESSID> |
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
CC=gcc | |
CFLAGS=-I. -Wall -pedantic -Werror -Wshadow -Wstrict-aliasing -Wstrict-overflow -g | |
all: main.o | |
$(CC) -o main main.o | |
.PHONY: clean | |
clean: |
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 colors = { | |
green: text => `\x1b[32m${text}\x1b[0m`, | |
red: text => `\x1b[31m${text}\x1b[0m`, | |
yellow: text => `\x1b[33m${text}\x1b[0m`, | |
blue: text => `\x1b[34m${text}\x1b[0m`, | |
}; | |
module.exports = colors; |
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
/** | |
* Verify a user (bypass email verification) | |
*/ | |
db.getCollection('users').update({ | |
"_id" : ObjectId("<users:record:_id>") | |
}, { | |
"$set": { | |
"verified": "yes" | |
} | |
}); |
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
// get a list of all verb ids | |
db.getCollection('statements').distinct('statement.verb.id'); | |
// get a list of all object activity ids | |
db.getCollection('statements').distinct( "statement.object.id"); | |
// get a list of object definition extension sub property values | |
db.getCollection('statements').distinct( "statement.object.definition.extensions.https://lxhive[dot].com/recipes/extensions/object.subType"); | |
// get a list of object id's containing "lesson" | |
db.getCollection('statements').find({"statement.object.id": /lesson/}); | |
// get a list of all verb display["en-US"] values | |
db.getCollection('statements').distinct('statement.verb.display.en-US'); |
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 | |
### | |
# Script for switching PHP versions | |
# Ubuntu 16.x dual php install. | |
# Instructions on how to set this up: http://robosparrow.github.io/2016/12/10/php-5-on-ubuntu16.html | |
### | |
GREEN="$(tput setaf 2)" | |
RED="$(tput setaf 1)" |
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
//..imports for rollup.config | |
//// | |
// plugin for copy | |
//// | |
import fs from 'fs'; | |
import path from 'path'; | |
const copyPlugin = function (options) { | |
return { |
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
{ | |
"name": "brightcookie/lxhive", | |
"description": "An open-source LRS from Brightcookie", | |
"license": "GPL-3.0", | |
"repositories": [ | |
{ | |
"type": "vcs", | |
"url": "https://github.com/sraka1/Slim" | |
} | |
], |
NewerOlder