├── .DS_Store ├── .gitattributes ├── LICENSE ├── README.md ├── qimage - support user-defined file name.alfredworkflow ├── qimage.alfredworkflow ├── qimage_from_clipboard.scpt ├── qimage_from_file.scpt └── res ├── file.gif ├── local.gif ├── paste.gif └── video.gif /.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jiwenxing/qimage-mac/c0701dcb5f2aed6f0845ec18ab886d78b6d05efb/.DS_Store -------------------------------------------------------------------------------- /.gitattributes: -------------------------------------------------------------------------------- 1 | *.scpt linguist-language=AppleScript -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2017 Jverson 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | 2 |
3 |

qimage-mac

4 | 5 | 6 | 7 |
8 | 9 | ___ 10 | 11 | **qimage-mac** 是一个 mac 中提升 markdown 贴图体验的实用小工具,基于 Alfred 实现,可以自定义快捷键,一键上传图片或截图至七牛云,获取图片的 markdown 引用至剪贴板,并自动粘贴到当前编辑器,使用简单方便。 12 | 13 | ## Changelog 14 | - v1.2 - 2020.01 15 | 1. 支持自定义图片url路径,如:在环境变量中指定环境变量`prefix`为`img/`则上传的图片url会变为 `http://cdn.example.com/img/cool.jpg`,而不是使用根目录`http://cdn.example.com/cool.jpg`。 16 | 2. 支持先压缩图片再上传(需安装[ImageOptim](https://imageoptim.com/mac)或者[optimage](https://optimage.app/),并填写`compressProvider`环境变量)。图片将拷贝一份再压缩,不会直接压缩原图。 17 | - v1.1 - 2017.11 - 针对 [issue #4](https://github.com/jiwenxing/qiniu-image-tool/issues/4) 新增支持自定义文件名称的 workflow :`support user-defined file name.alfredworkflow` 18 | 特点: 19 | 1. 上传本地图片则默认使用原图片名称 20 | 2. 上传截图或网络图片时,会弹窗提示输入自定义图片名称 21 | 22 | ## Usage 23 | 详细的使用教程请参考:[使用alfred在markdown中愉快的贴图](http://jverson.com/2017/04/28/alfred-qiniu-upload/) 24 | windows版本请移步至:https://github.com/jiwenxing/qiniu-image-tool-win 25 | 26 | 27 | ## Features 28 | - 支持jpg、png、bmp及gif等各种图片格式 29 | - 支持截图及网络图片直接复制上传 30 | - 支持各种其它格式本地文件上传,返回资源引用 31 | - 上传失败或成功通知栏会有相应提示 32 | - 使用简单,只需配置环境变量即可 33 | 34 | ## Requirements 35 | **`Alfred with Powerpack`** **`qshell`** **`七牛账号`** 36 | 37 | ## Preview 38 | 1. 本地图片文件上传
39 | ![](https://raw.githubusercontent.com/jiwenxing/qiniu-image-tool/master/res/local.gif) 40 | 41 | 2. 截图上传
42 | ![](https://github.com/jiwenxing/qiniu-image-tool/blob/master/res/paste.gif?raw=true) 43 | 44 | 3. 其它文件上传
45 | ![](https://raw.githubusercontent.com/jiwenxing/qiniu-image-tool/master/res/file.gif) 46 | 47 | 48 | 49 | 注:演示gif使用macdown及licecap制作 50 | 51 | ## To-do 52 | 1. 文件名中如果包含空格,图片将上传不成功 53 | 2. 文件名没有加类似`.jpg`后缀,不会自动补齐。 54 | 55 | 56 | # License 57 | [MIT License](https://raw.githubusercontent.com/jiwenxing/qiniu-image-tool/master/LICENSE). 58 | Copyright (c) 2017 Jverson 59 | 60 | 61 | 62 | 63 | 64 | 65 | -------------------------------------------------------------------------------- /qimage - support user-defined file name.alfredworkflow: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jiwenxing/qimage-mac/c0701dcb5f2aed6f0845ec18ab886d78b6d05efb/qimage - support user-defined file name.alfredworkflow -------------------------------------------------------------------------------- /qimage.alfredworkflow: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jiwenxing/qimage-mac/c0701dcb5f2aed6f0845ec18ab886d78b6d05efb/qimage.alfredworkflow -------------------------------------------------------------------------------- /qimage_from_clipboard.scpt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jiwenxing/qimage-mac/c0701dcb5f2aed6f0845ec18ab886d78b6d05efb/qimage_from_clipboard.scpt -------------------------------------------------------------------------------- /qimage_from_file.scpt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jiwenxing/qimage-mac/c0701dcb5f2aed6f0845ec18ab886d78b6d05efb/qimage_from_file.scpt -------------------------------------------------------------------------------- /res/file.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jiwenxing/qimage-mac/c0701dcb5f2aed6f0845ec18ab886d78b6d05efb/res/file.gif -------------------------------------------------------------------------------- /res/local.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jiwenxing/qimage-mac/c0701dcb5f2aed6f0845ec18ab886d78b6d05efb/res/local.gif -------------------------------------------------------------------------------- /res/paste.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jiwenxing/qimage-mac/c0701dcb5f2aed6f0845ec18ab886d78b6d05efb/res/paste.gif -------------------------------------------------------------------------------- /res/video.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jiwenxing/qimage-mac/c0701dcb5f2aed6f0845ec18ab886d78b6d05efb/res/video.gif --------------------------------------------------------------------------------