Skip to content

Instantly share code, notes, and snippets.

@Senorsen
Created May 20, 2016 14:53
Show Gist options
  • Save Senorsen/1c07fb7b29d424a78762ac122eacb24d to your computer and use it in GitHub Desktop.
Save Senorsen/1c07fb7b29d424a78762ac122eacb24d to your computer and use it in GitHub Desktop.
no sucks with windows ping.exe in cygwin & msys for chinese (gbk <-> utf-8)
#!/bin/sh
# Usage: winprog ping 8.8.8.8
# Hint: you can write a shell: ~/bin/ping, and call this script
iconv -f utf-8 -t gbk | $@ | iconv -f gbk -t utf-8
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment