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
// | |
// NSObject.swift | |
// QBDemo01 | |
// | |
// Created by 默司 on 2016/12/2. | |
// Copyright © 2016年 默司. All rights reserved. | |
// | |
import Foundation |
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
const express = require('express'); | |
const mongodb = require('mongodb'); | |
const app = express(); | |
function to(promise) { | |
if (!(promise instanceof Promise)) { | |
promise = Promise.resolve(promise); | |
} | |
return promise.then(res => [null, res]).catch(err => [err]); |
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
$scope.get_romig_24g=function(){ | |
return $scope.handle().then(function(res){ | |
console.log("$scope.ip[0] "+ $scope.ip[0]) | |
console.log("res "+res) | |
let url= "http://"+res+"/boafrm/formWlanRedirect?redirect-url=/wladvanced.htm&wlan_id=1" | |
return url | |
},function(err){ | |
console.log(err) | |
err=err+"no ip" | |
return err |
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 React from 'react'; | |
import { Query } from "react-apollo"; | |
import hoist from 'hoist-non-react-statics'; | |
import compareProps from '../compareProps'; | |
const withQuery = (query, { name, options = {}, mapPropKeys = [] }) => (WrappedComponent) => { | |
class WithQuery extends React.Component { | |
constructor() { | |
super(); |
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 | |
curl -sSL get.docker.com | sh - | |
git clone -b mujson https://github.com/mosluce/shadowsocksr | |
cd shadowsocksr | |
docker build -t ssr . | |
docker run -d --restart=always -p 6540-6550:6540-6550 --name ssr ssr | |
for (( i=1; i<=2; i++ )) | |
do |
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 React, { PureComponent } from "react"; | |
import { | |
View, | |
TextInput, | |
TextInputProps, | |
ViewStyle, | |
TextStyle, | |
StyleProp, | |
Platform, | |
} from "react-native"; |
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 React, { PureComponent } from "react"; | |
import { | |
View, | |
Text, | |
TouchableWithoutFeedback, | |
Picker, | |
PickerItemProps, | |
Modal, | |
Animated, | |
TouchableWithoutFeedbackProps, |
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
using System.Collections; | |
using System.Collections.Generic; | |
using UnityEngine; | |
using UnityEngine.Networking; | |
public class LoadJson : MonoBehaviour | |
{ | |
// Use this for initialization | |
IEnumerator Start() |
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 Circle(Vector3 center, Vector3 normal, int polyAmount, float radius) | |
{ | |
this.normal = normal.normalized; | |
this.center = center; | |
var z = Vector3.forward; | |
var dot = Vector3.Dot(z, normal); | |
var y = z - dot * normal; | |
if (dot == 1 || dot == -1) |
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 | |
apt-get update | |
apt-get install -y git-core | |
curl -sSL get.docker.com | sh - | |
git clone -b mujson https://github.com/mosluce/shadowsocksr.git | |
cd shadowsocksr |