Skip to content

Instantly share code, notes, and snippets.

import {Sql} from "../providers/Sql";
export class ExamplePage {
constructor(private sql: Sql) {
//sql.query(...);
//...
}
}
@PurpleBooth
PurpleBooth / README-Template.md
Last active April 26, 2024 11:27
A template to make good README.md

Project Title

One Paragraph of project description goes here

Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.

Prerequisites

@tonymtz
tonymtz / gist:d75101d9bdf764c890ef
Last active December 29, 2023 00:40
Uninstall nodejs from OSX Yosemite
# first:
lsbom -f -l -s -pf /var/db/receipts/org.nodejs.pkg.bom | while read f; do sudo rm /usr/local/${f}; done
sudo rm -rf /usr/local/lib/node /usr/local/lib/node_modules /var/db/receipts/org.nodejs.*
# To recap, the best way (I've found) to completely uninstall node + npm is to do the following:
# go to /usr/local/lib and delete any node and node_modules
cd /usr/local/lib
sudo rm -rf node*
@Ovid
Ovid / gist:0674ef8fe906f10cc8f2
Created July 5, 2014 18:43
Procedural quest generation
#!/usr/bin/env perl
use 5.10.0;
use strict;
use warnings;
use Getopt::Long;
use Data::Dumper;
$Data::Dumper::Indent = 0;
$Data::Dumper::Terse = 1;
@mhartington
mhartington / CustomTheme
Last active December 8, 2018 20:35
If you want to make a custom theme for ionic, and are using scss, this is a base to get you started
//Custom Theme test
// Colors
// -------------------------------
$custom: #057b6c !default;
// Buttons
// -------------------------------
$button-custom-bg: $custom !default;
@DanHerbert
DanHerbert / fix-homebrew-npm.md
Last active February 12, 2024 17:18
Instructions on how to fix npm if you've installed Node through Homebrew on Mac OS X or Linuxbrew

OBSOLETE

This entire guide is based on an old version of Homebrew/Node and no longer applies. It was only ever intended to fix a specific error message which has since been fixed. I've kept it here for historical purposes, but it should no longer be used. Homebrew maintainers have fixed things and the options mentioned don't exist and won't work.

I still believe it is better to manually install npm separately since having a generic package manager maintain another package manager is a bad idea, but the instructions below don't explain how to do that.

Fixing npm On Mac OS X for Homebrew Users

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.

@AlexHunterCodes
AlexHunterCodes / unity.gitignore
Created January 25, 2014 20:36
Unity 4.x .gitignore
### https://raw.github.com/github/gitignore/master/Global/Windows.gitignore
# Windows image file caches
Thumbs.db
ehthumbs.db
# Folder config file
Desktop.ini
# Recycle Bin used on file shares
@malarkey
malarkey / Three Wise Monkeys.md
Created December 2, 2012 14:26
Three Wise Monkeys (NDA)

Date: [date]

Between us [company name] and you [customer name].

Summary:

In short; neither of us will share any confidential information about each-other, by any means, with anyone else.

What’s confidential information?

@cspencegists
cspencegists / gist:4111969
Created November 19, 2012 17:09
Corona SDK: Monitor Memory Usage
-- @DEBUG monitor Memory Usage
local printMemUsage = function()
local memUsed = (collectgarbage("count"))
local texUsed = system.getInfo( "textureMemoryUsed" ) / 1048576 -- Reported in Bytes
print("\n---------MEMORY USAGE INFORMATION---------")
print("System Memory: ", string.format("%.00f", memUsed), "KB")
print("Texture Memory:", string.format("%.03f", texUsed), "MB")
print("------------------------------------------\n")
end
@malarkey
malarkey / Contract Killer 3.md
Last active April 16, 2024 21:44
The latest version of my ‘killer contract’ for web designers and developers

When times get tough and people get nasty, you’ll need more than a killer smile. You’ll need a killer contract.

Used by 1000s of designers and developers Clarify what’s expected on both sides Helps build great relationships between you and your clients Plain and simple, no legal jargon Customisable to suit your business Used on countless web projects since 2008

…………………………