This file was generated automatically based on this two sources:
- /etc/nginx/mime.types
- http://www.garykessler.net/library/file_sigs.html
This is a JSON object by following structure:
[string ext] : {
signs: [sign]
| #!/bin/bash | |
| export COLOR_NC='\e[0m' | |
| export COLOR_GREEN='\e[0;32m' | |
| export COLOR_RED='\e[0;31m' | |
| export INTERFACE='wlp3s0' | |
| if [ "`nmcli networking`" == "enabled" ]; then | |
| printf "${COLOR_GREEN}networking enabled${COLOR_NC}\n" | |
| else |
This file was generated automatically based on this two sources:
This is a JSON object by following structure:
[string ext] : {
signs: [sign]
| var app = angular.module("app", ["ngTreant"]); | |
| angular.module('ngTreant', []) | |
| .directive('treantGraph', function () { | |
| return { | |
| restrict: 'E', | |
| scope: { | |
| data: '=data' | |
| }, | |
| template: '<div class="chart" id="example-graph"></div>', |
| function get(path, obj, fb = `$\{${path}}`) { | |
| return path.split('.').reduce((res, key) => res[key] || fb, obj); | |
| } | |
| function parseTpl(template, map, fallback) { | |
| return template.replace(/\$\{.+?}/g, (match) => { | |
| const path = match.substr(2, match.length - 3).trim(); | |
| return get(path, map, fallback); | |
| }); | |
| } |
| const CustomError = function CustomError() { | |
| if (Error.captureStackTrace) { // Chrome | |
| Error.captureStackTrace(this, CustomError); | |
| } else { | |
| const err = new Error(); | |
| let processedStack, fileName, lineNumber; | |
| Object.defineProperties(this, { | |
| stack: { | |
| get: function() { |
| export class EnumSymbol { | |
| sym = Symbol.for(name); | |
| value: number; | |
| description: string; | |
| constructor(name: string, {value, description}) { | |
| if(!Object.is(value, undefined)) this.value = value; | |
| if(description) this.description = description; |
| /** | |
| * This code is licensed under the terms of the MIT license | |
| * | |
| * Deep diff between two object, using lodash | |
| * @param {Object} object Object compared | |
| * @param {Object} base Object to compare with | |
| * @return {Object} Return a new object who represent the diff | |
| */ | |
| function difference(object, base) { | |
| function changes(object, base) { |
| /** | |
| * Produces a function which uses template strings to do simple interpolation from objects. | |
| * | |
| * Usage: | |
| * var makeMeKing = generateTemplateString('${name} is now the king of ${country}!'); | |
| * | |
| * console.log(makeMeKing({ name: 'Bryan', country: 'Scotland'})); | |
| * // Logs 'Bryan is now the king of Scotland!' | |
| */ | |
| var generateTemplateString = (function(){ |
| // this is now a module: | |
| // https://github.com/WebReflection/backtick-template#es2015-backticks-for-es3-engines-- | |
| var template = require('backtick-template'); | |
| // just string | |
| const info = 'template'; | |
| `some ${info}` === template('some ${info}', {info}); |
| // source: http://doublespringlabs.blogspot.com.br/2012/11/decoding-polylines-from-google-maps.html | |
| function decode(encoded){ | |
| // array that holds the points | |
| var points=[ ] | |
| var index = 0, len = encoded.length; | |
| var lat = 0, lng = 0; | |
| while (index < len) { | |
| var b, shift = 0, result = 0; |