Mac自带的Boot Camp程序,可以非常便利地帮助用户在Mac电脑上同时安装一个Windows系统。针对Macbook Air用户,这里记录下在没有光驱的情况下,使用USB制作启动盘来安装Windows的过程。
1、U盘一个(>= 4g) 2、win7镜像文件(.iso) 3、rEFIT.dmg(用于让不支持USB等外设设备启动引导的设备能识别USB设备启动)
/** | |
* 跨域iframe自适应高度脚本 | |
*/ | |
var Loader = new function(){ | |
var doc = document,body = doc.body, | |
self = this, | |
//获取url中的参数 | |
getRequest = function(name) { | |
var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)","i"), |
FROM python:3.6 | |
ADD . /app | |
WORKDIR /app | |
# | |
RUN pip install --upgrade pip | |
RUN pip install -r requirements.txt | |
# install node and npm for query thumbnail process | |
RUN curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.33.11/install.sh | bash |
"""Run the unit tests.""" | |
import unittest | |
import sys | |
def iterate_test_cases(test_suite_or_case): | |
"""Iterate through all of the test cases in 'test_suite_or_case'.""" | |
try: | |
suite = iter(test_suite_or_case) | |
except TypeError: |
这是Meteor的大坑,希望以后这块能做的更好。
首先,在Meteor中,由于经过了沙箱的封装,无法直接触碰到require, module等全局变量。
且,Meteor会自动执行所有不在test
,public
目录下的js文件,因此我们需要使用的npm模块都需要安装到public目录下。
然后使用meteor-node-module进行模块的加载。
举例,我们现在需要使用mustache
,那么cd
到public
目录下,安装之npm install mustache
,然后在我们的代码中使用:
/* eslint-disable */ | |
import { createSelectorCreator } from 'reselect'; | |
function execFunc(func, ...args) { | |
return func(...args); | |
} | |
function multipleCacheMemoize(func) { | |
const argsArray = []; | |
const resultArray = []; |
git ftp catchup -u username -p password --remote-root htdoc/daigou --syncroot build --version --verbose ftp://host.example.com:21 |
// @link https://github.com/reactjs/react-router/blob/v0.13.3/examples/partial-app-loading/app.js | |
var React = require('react'); | |
var Router = require('react-router'); | |
var { Route, RouteHandler, Link } = Router; | |
var AsyncElement = { | |
loadedComponent: null, | |
load: function () { | |
if (this.constructor.loadedComponent) |
PhoneGap的插件机制为我们提供了自由拓展Native API的可能。但是网络上和PhoneGap插件开发相关的资料较少,本文介绍插件开发的简单过程。
参考资料:
How to Create a PhoneGap Plugin for Android
Migrating your PhoneGap Plugins to Version 1.5+
##PhoneGap的Plugin原理