git reset HEAD^
Some Zsh users know what would happen when we type that commands:
zsh: no matches found: HEAD^
zsh: no matches found: install[classic]
This is caused by Zsh:
zsh allows Filename Generation and Pattern Matching (Globbing) using square brackets and other characters (explained in the zsh guide, section 5.9).
The solution is simple:
The solution, found in the zsh FAQ (section 3.4), is simply adding a line in ~/.zshrc that disables globbing for a single command:
alias rake="noglob rake"
gitis also useful:
alias git="noglob git"
“Backdoor” can be abused by gov’t agents and ex-lovers to gain persistent access.
Apple has endowed iPhones with undocumented functions that allow unauthorized people in privileged positions to wirelessly connect and harvest pictures, text messages, and other sensitive data without entering a password or PIN, a forensic scientist warned over the weekend.
Zdziarski said the service that raises the most concern is known as com.apple.mobile.file_relay. It dishes out a staggering amount of data—including account data for e-mail, Twitter, iCloud, and other services, a full copy of the address book including deleted entries, the user cache folder, logs of geographic positions, and a complete dump of the user photo album—all without requiring a backup password to be entered. He said two other services dubbed com.apple.pcapd and com.apple.mobile.house_arrest may have legitimate uses for app developers or support people but can also be used to spy on users by government agencies or even jilted ex-lovers. The Pcapd service, for instance, allows people to wirelessly monitor all network traffic traveling into and out of the device, even when it’s not running in a special developer or support mode. House_arrest, meanwhile, allows the copying of sensitive files and documents from Twitter, Facebook, and many other applications.
Slides of Zdziarski’s talk, titled Identifying Back Doors, Attack Points, and Surveillance Mechanisms in iOS Devices are here.
Also check the page about iOS: About diagnostic capabilities on Apple Support:
Each of these diagnostic capabilities requires the user to have unlocked their device and agreed to trust another computer. Any data transmitted between the iOS device and trusted computer is encrypted with keys not shared with Apple. For users who have enabled iTunes Wi-Fi Sync on a trusted computer, these services may also be accessed wirelessly by that computer.
Keybase will be a public directory of publicly auditable public keys. All paired, for convenience, with unique usernames.
I just created my Keybase. You can see my PGP public key on keybase.io/yous and get the key via
https://keybase.io/yous/key.asc. Anyone can encrypt messages using my public key and then I could decrypt it using my private key and see the message with safety. All of these can be done in browser, in Keybase.
Keybase provides several ways to prove own identity of a Twitter account, a GitHub account, websites and a bitcoin address. Still it can be done on the browser, also you can use command line for it. I proved my GitHub by keybase.md and this site by keybase.txt. Also you can check it with command line like:
$ keybase id yous ✔ public key fingerprint: 1BF1 AFE8 682E 45A2 11FF 2C0E 891B 7A9E 1D5A 400A ✔ "yous" on github: https://gist.github.com/149b0775d2ff02eac323 ✔ admin of yous.be via HTTP: http://yous.be/keybase.txt
I wrote “How to Add Redirects to Post URL on Octopress” few month ago. Now Octopress is compatible with Jekyll 2.0, and some plugins don’t seem to work. Current Octopress uses Jekyll 2.0.3 and when I run
rake generate, I see an error:
/path/to/jekyll/lib/jekyll/static_file.rb:40:in `stat': Not a directory @ rb_file_s_stat - /path/to/generated/alias/index.html/ (Errno::ENOTDIR)
So I make this commit:
diff --git a/_plugins/alias_generator.rb b/_plugins/alias_generator.rb index 1d24cd8..50e9404 100644 --- a/_plugins/alias_generator.rb +++ b/_plugins/alias_generator.rb @@ -70,9 +70,10 @@ module Jekyll file.write(alias_template(destination_path)) end - (alias_index_path.split('/').size + 1).times do |sections| + alias_index_path.split('/').size.times do |sections| @site.static_files << Jekyll::AliasFile.new(@site, @site.dest, alias_index_path.split('/')[0, sections].join('/'), '') end + @site.static_files << Jekyll::AliasFile.new(@site, @site.dest, alias_dir, alias_file) end end
diff --git a/_plugins/alias_generator.rb b/_plugins/alias_generator.rb index 50e9404..76102db 100644 --- a/_plugins/alias_generator.rb +++ b/_plugins/alias_generator.rb @@ -56,13 +56,13 @@ module Jekyll alias_paths.compact! alias_paths.flatten.each do |alias_path| - alias_path = alias_path.to_s + alias_path = File.join('/', alias_path.to_s) alias_dir = File.extname(alias_path).empty? ? alias_path : File.dirname(alias_path) alias_file = File.extname(alias_path).empty? ? "index.html" : File.basename(alias_path) - fs_path_to_dir = File.join(@site.dest, alias_dir) - alias_index_path = File.join(alias_dir, alias_file) + fs_path_to_dir = File.join(@site.dest, alias_dir) + alias_sections = alias_dir.split('/')[1..-1] FileUtils.mkdir_p(fs_path_to_dir) @@ -70,8 +70,8 @@ module Jekyll file.write(alias_template(destination_path)) end - alias_index_path.split('/').size.times do |sections| - @site.static_files << Jekyll::AliasFile.new(@site, @site.dest, alias_index_path.split('/')[0, sections].join('/'), '') + alias_sections.size.times do |sections| + @site.static_files << Jekyll::AliasFile.new(@site, @site.dest, alias_sections[0, sections + 1].join('/'), '') end @site.static_files << Jekyll::AliasFile.new(@site, @site.dest, alias_dir, alias_file) end
To say the result first, I had no luck. The alias directories are generated, every
index.htmlfile under each directory won’t. By looking at diff of
sitemap.xml, the plugin seems to generate wrong paths. I’m pretty newbie to Jekyll and how Octopress works with it. Also this is a plugin for Jekyll, not Octopress. So if you have any fix for this problem, please make pull requests to jekyll_alias_generator or just contact me.