mac使用caffeinate放休眠

不想装第三方(Amphetamine之类的),mac原生自带caffeinate命令防休眠

1
2
3
4
5
6
7
8
9
10
-d Create an assertion to prevent the display from sleeping.
-i Create an assertion to prevent the system from idle sleeping.
-m Create an assertion to prevent the disk from idle sleeping.
-s Create an assertion to prevent the system from sleeping. This assertion is valid only when system is running on AC power.
-u Create an assertion to declare that user is active. If the display is off, this option turns the display on and prevents the display from going
into idle sleep. If a timeout is not specified with '-t' option, then this assertion is taken with a default of 5 second timeout.

配合alfredCaffeinate Control效果拔群。

osx

osx 10.13 python SSL报错(ssl module in Python is not available)

待更新。。。

###问题描述

1
2
3
4
5
6
$ pip install pyopenssl --trusted-host pypi.python.org
pip is configured with locations that require TLS/SSL, however the ssl module in Python is not available.
Collecting pyopenssl
Could not fetch URL https://pypi.python.org/simple/pyopenssl/: There was a problem confirming the ssl certificate: Can't connect to HTTPS URL because the SSL module is not available. - skipping
Could not find a version that satisfies the requirement pyopenssl (from versions: )
No matching distribution found for pyopenssl

From Python Developer’s Guide

As of OS X 10.11, Apple no longer provides header files for the deprecated system version of OpenSSL which means that you will not be able to build the _ssl extension.

osx

osx transfer file to android

一百年没写的blog
osx没法读android的mtp然后用airdrop真的是慢道靠背,还好可以用adb传东西。

1
2
3
4
$ adb root
$ adb remount
//确保可以rw
$adb push Downloads/Persona_JPN_PSP-Caravan/cvn-persona.iso /sdcard/persona.iso
osx

firefox关闭javascript

访问about:config

javascript.enabled设置为false.

这样就可以直接复制一些需要登录才能复制的网页上的内容了(比如360doc)。