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
import sqlite3, os | |
conn = sqlite3.connect('Mills1860.mbtiles') | |
results=conn.execute('select * from tiles').fetchall() | |
for result in results: | |
zoom, column, row, png= result | |
try: | |
os.makedirs('%s/%s/' % (zoom, row)) |
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
<?xml version="1.0"?> | |
<!DOCTYPE Configure PUBLIC "-//Jetty//Configure//EN" "http://www.eclipse.org/jetty/configure.dtd"> | |
<Configure class="org.eclipse.jetty.server.Server"> | |
<Set name="connectors"> | |
<Array type="org.eclipse.jetty.server.Connector"> | |
<Item> | |
<New class="org.eclipse.jetty.server.nio.SelectChannelConnector"> | |
<Set name="Port"><SystemProperty name="jetty.port" default="8080"/></Set> | |
</New> |
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
package com.appspot.dangt85.controllers; | |
import java.io.IOException; | |
import java.io.InputStreamReader; | |
import java.io.UnsupportedEncodingException; | |
import java.net.URLEncoder; | |
import javax.servlet.ServletException; | |
import javax.servlet.http.HttpServletRequest; | |
import javax.servlet.http.HttpServletResponse; |
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
<?xml version="1.0" encoding="UTF-8"?> | |
<beans xmlns="http://www.springframework.org/schema/beans" | |
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | |
xmlns:util="http://www.springframework.org/schema/util" | |
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd | |
http://www.springframework.org/schema/util http://www.springframework.org/schema/util/spring-util-3.0.xsd"> | |
<bean id="systemProps" class="org.springframework.beans.factory.config.MethodInvokingFactoryBean"> | |
<property name="targetObject" value="#{@systemProperties}" /> | |
<property name="targetMethod" value="putAll" /> |
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
Merchandise__c[] ml = new List<Merchandise__c>(); | |
Merchandise__c m = new Merchandise__c( | |
Name='Pencils', | |
Description__c='Cool pencils', | |
Price__c=1.5, | |
Total_Inventory__c=1000); | |
ml.add(m); | |
Merchandise__c m2 = new Merchandise__c( | |
Name='Notebooks', | |
Description__c='Blue notebooks', |
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 python | |
import sys | |
# input comes from STDIN (standard input) | |
for line in sys.stdin: | |
# remove leading and trailing whitespace | |
line = line.strip() | |
# split the line into words | |
words = line.split('|') |
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
<!-- | |
Author - Mohit Shrivastav | |
Co-Author - Harshit Pandey (Revised Code) | |
// ======== Angular JS with Visualforce ==== | |
This page list down the fields of Account and list the fields by Querying Salesforce | |
User can search sort and paginate the data presentation pretty quickly and fancy way | |
using Angular.JS | |
--> |
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
apply plugin: 'java' | |
apply plugin : 'war' | |
group = 'com.cadrlife' | |
version = '1.0.0' | |
buildscript { | |
repositories { | |
mavenCentral() | |
} |
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 | |
# Run this: | |
# | |
# curl https://gist.github.com/nicerobot/7664605/raw/install.sh | bash -s do-sudo | |
# | |
# which will run: | |
[ -f qgis2-homebrew-build.sh ] || { | |
curl -O https://gist.github.com/nicerobot/7664605/raw/qgis2-homebrew-build.sh |
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
public with sharing class ViewStateStudy_controller { | |
public String accId{get;set;} | |
public Account account{get;set;} | |
public ViewStateStudy_controller() | |
{ | |
accId = ApexPages.currentPage().getParameters().get('Id'); | |
if(accId != null) | |
{ |
OlderNewer