- add a new file in
app/models/quiz_question/
that extendsQuizQuestion::Base
(or another question type) - extend the appropriate scoring functions:
- stats
- total_answer_parts
- correct_answer_parts
- incorrect_answer_parts
- requires_manual_scoring?
/** | |
* Module dependencies | |
*/ | |
var express = require('express'); | |
var fs = require('fs'); | |
var mongoose = require('mongoose'); | |
var Schema = mongoose.Schema; | |
// img path |
#!/usr/bin/env python | |
# -*- coding: utf-8 -*- | |
""" Clash of Clans Auto Tool for Genymotion (VirtualBox Android VM) | |
""" | |
import os | |
import sys | |
import virtualbox | |
import subprocess | |
import cv2.cv as cv |
/* | |
* IF YOU WANT TO JUST ACCESS THE CAMERA INSTANCE SO THAT YOU CAN SET ANY OF THE PARAMETERS, VISIT THE FOLLOWING LINK: | |
* https://gist.github.com/Gericop/364dd12b105fdc28a0b6 | |
*/ | |
/** | |
* <p> | |
* Sets the Mobile Vision API provided {@link com.google.android.gms.vision.CameraSource}'s | |
* focus mode. Use {@link Camera.Parameters#FOCUS_MODE_CONTINUOUS_PICTURE} or | |
* {@link Camera.Parameters#FOCUS_MODE_CONTINUOUS_VIDEO} for continuous autofocus. |
<?xml version="1.0" encoding="UTF-8"?> | |
<project name="application-custom"> | |
<macrodef name="git" taskname="@{taskname}"> | |
<attribute name="command" /> | |
<attribute name="dir" default="" /> | |
<attribute name="property" default="" /> | |
<attribute name="taskname" default="" /> | |
<attribute name="failonerror" default="on" /> | |
<element name="args" optional="true" /> |
#!/bin/bash | |
# Returns the IP address of a running KVM guest VM | |
# Assumes a working KVM/libvirt environment | |
# | |
# Install: | |
# Add this bash function to your ~/.bashrc and `source ~/.bashrc`. | |
# Usage: | |
# $ virt-addr vm-name | |
# 192.0.2.16 | |
# |
#!/bin/sh | |
# Alot of these configs have been taken from the various places | |
# on the web, most from here | |
# https://github.com/mathiasbynens/dotfiles/blob/master/.osx | |
# Set the colours you can use | |
black='\033[0;30m' | |
white='\033[0;37m' | |
red='\033[0;31m' |
Movies Recommendation:
Music Recommendation:
#!/bin/bash | |
# Installing the Xcode command line tools on 10.7.x or higher | |
osx_vers=$(sw_vers -productVersion | awk -F "." '{print $2}') | |
cmd_line_tools_temp_file="/tmp/.com.apple.dt.CommandLineTools.installondemand.in-progress" | |
# Installing the latest Xcode command line tools on 10.9.x or higher | |
if [[ "$osx_vers" -ge 9 ]]; then |
Installing node through Homebrew can cause problems with npm for globally installed packages. To fix it quickly, use the solution below. An explanation is also included at the end of this document.
This solution fixes the error caused by trying to run npm update npm -g
. Once you're finished, you also won't need to use sudo
to install npm modules globally.
Before you start, make a note of any globally installed npm packages. These instructions will have you remove all of those packages. After you're finished you'll need to re-install them.