Skip to content

Instantly share code, notes, and snippets.

View brambow's full-sized avatar

brambow brambow

View GitHub Profile
@indyfromoz
indyfromoz / aspnet-mvc.gitignore
Created November 19, 2012 06:44
.Gitignore for ASP.NET MVC
###################
# compiled source #
###################
*.com
*.class
*.dll
*.exe
*.pdb
*.dll.config
*.cache
@oeon
oeon / pgRouting_intro.md
Last active February 27, 2022 09:44
basic steps with pgRouting to make alpha shape of isochrone
  1. createdb with postgres > create postgis/pgrouting extension > load road data with ogr2ogr or shp2pgsql or SPIT in QGIS

  2. create vertices_tmp table with id/geom columns

select pgr_createTopology('roads', 0.5, 'geom', 'id');

  1. from 29788 = to the nearest 'vertices_tmp' node id to Station 15, select #all nodes less than 10 units (minutes) of cost
SELECT id, id1 AS node, id2 AS edge, cost, the_geom
INTO "20_10min_nodes"
@davestevens
davestevens / LetsEncrypt.md
Last active November 6, 2024 11:48
Let’s Encrypt setup for Apache, NGINX & Node.js

Let's Encrypt

Examples of getting certificates from Let's Encrypt working on Apache, NGINX and Node.js servers.

Obtain certificates

I chose to use the manual method, you have to make a file available to verify you own the domain. Follow the commands from running

git clone https://github.com/letsencrypt/letsencrypt
cd letsencrypt
@mdang
mdang / RAILS_CHEATSHEET.md
Last active November 4, 2024 15:59
Ruby on Rails Cheatsheet

Ruby on Rails Cheatsheet

Architecture

Create a new application

Install the Rails gem if you haven't done so before

@bmcbride
bmcbride / gdal_geotiff_to_mbtiles.txt
Created December 15, 2016 16:10
GDAL commands to convert GeoTiff image to MBTiles. Requires GDAL 2.1+.
gdal_translate image.tif image.mbtiles -of MBTILES
gdaladdo image.mbtiles 2 4 8
'use strict'
import React, { Component } from 'react'
import PropTypes from 'prop-types'
import { Table, Menu, Icon, Segment, Input } from 'semantic-ui-react'
import capitalize from 'lodash/capitalize'
import flatten from 'lodash/flatten'
import orderBy from 'lodash/orderBy'
import debounce from 'lodash/debounce'
@AbelVM
AbelVM / LICENSE
Last active November 3, 2023 16:09
ST_KDensity: a simple spatial kernel density function for PostGIS
The MIT License (MIT)
Copyright (c) 2018 Abel Vázquez Montoro
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
import React, { useState, useEffect, createContext, useContext, ReactNode } from 'react'
import Amplify, { Auth, Hub } from 'aws-amplify'
import { CognitoUser } from '@aws-amplify/auth'
import { CognitoUserSession } from 'amazon-cognito-identity-js'
import { HubCallback } from '@aws-amplify/core/lib/Hub'
import IUser from '../../types/IUser'
interface IAuthContext {
user: IUser | null
login(username: string, password: string): Promise<CognitoUser>