Skip to content

Instantly share code, notes, and snippets.

@iahu
Created July 17, 2019 07:23
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save iahu/2664e8965f33c7f2a6d711ffa6e7841c to your computer and use it in GitHub Desktop.
Save iahu/2664e8965f33c7f2a6d711ffa6e7841c to your computer and use it in GitHub Desktop.
通过 AppleScript 实现快速更新 iconfont.cn 网站 css 版本更新
  1. 通过在 Mac OSX 的 Automator 上创建一个 “快速操作” 可以为浏览器添加一个自定义的右键菜单命令。

  2. 再利用脚本去更新对应文件就可以实现 css 版本的快速更新了。

sed -i '' "s/font_[^\"]*\.css/$@.css/" /path/to/target/file.html
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment