- Put
pyinstxtractor.py
to somewhere included inPATH
by cloningpython-exe-unpacker
or just downloading - Clone
python-uncompyle6
, patch it if on Windows, install - Also put
pycize.py
anddepyinstaller.cmd
along withpyinstxtractor.py
depyinstaller foo.exe
and get source- If
foo
is not the real entry name, try to find the real name among the extracted folder, then do the rest
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 fs = require('fs') | |
fs.readFile('yarn.lock', { encoding: 'utf8' }, (err, data) => { | |
if (err) { | |
console.error(err) | |
process.exit(1) | |
} else { | |
fs.writeFileSync('yarn.lock', data.replace(/"https:\/\/registry\.yarnpkg\.com\/.+"/g, url => { | |
url = url.replace('registry.yarnpkg.com', 'registry.npm.taobao.org') | |
if (url.includes('/-/')) { | |
const match = url.match(/\/@[^/]+\//) |
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
"use strict"; | |
var page = require('webpage').create(); | |
var system = require('system'); | |
if (system.args.length !== 2) { | |
system.stderr.writeLine('Put target URL as argument'); | |
} else { | |
var url = system.args[1]; | |
} | |
page.viewportSize = { width: 1080, height: 1920 }; | |
page.open(url, function (status) { |
Docker容器和服务中持久化数据的最佳方案。用例包括:
- 多个运行中的容器间共享数据。不手动建立时,卷会在首次挂载到容器时创建。卷不因容器停止或移除被删除。多个容器能同时挂载同一个容器,并可设定只读/读写。卷只会被手动明确删除。
- Docker主机不一定有确定的目录文件结构时,卷有助于将容器运行环境与Docker主机配置解耦。
- 需要将容器数据储存在远程主机或云服务上,而不仅仅存在本地。
- 需要在Docker主机间备份、还原、迁移数据的话是更好的选择。可在停止使用该卷的容器后,备份卷所在的目录(例如/var/lib/docker/volumes/<卷名>)
一般来说尽量用卷。绑定挂载适用于下列用例:
- 容器共享主机的配置文件。Docker默认为容器提供DNS解析就是用挂载主机文件/etc/resolv.conf到各个容器实现的。
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
<!DOCTYPE html> | |
<html lang="zh-cn" dir="ltr"> | |
<head> | |
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> | |
<title>SHIFTJIS</title></head> | |
<body> | |
<p><?php | |
if(isset($_POST['subject'])){ | |
$s = $_POST['subject']; | |
if(!empty($s)){ |
本文档内容基于Drew Neil著作Pratical Vim中译本整理。
- 能够前往其他任一Vim模式
- 字符命令形式:
[{count}=1]{operator}
,对光标下起的count个字符执行操作并后移光标。 - 动作命令形式:
[{count}=1]{operator}{motion}
,表示执行operator操作,作用于当前光标+motion指定的范围,并执行count次。 - 行命令形式:对于动作命令,
{operator}{operator}
表示将该操作作用于当前行;guu
和gUU
是作用于当前行的简化版。 - 操作符和动作命令均可以自定义,也可与已有的操作符和动作命令组合使用。
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
// vim: set et sw=2 ts=2 sts=2 ff=unix fenc=utf8: | |
// Author: Binux<[email protected]> | |
// http://binux.me | |
// acgrid<[email protected]> | |
// Created on 2013-04-20 20:17:45 | |
define(['underscore', 'utils', 'jquery'], function(__,utils,$) { | |
return { | |
choice_piece_size: function() { |