开源软件名称(OpenSource Name):toolinbox/iPicUploader开源软件地址(OpenSource Url):https://github.com/toolinbox/iPicUploader开源编程语言(OpenSource Language):Swift 92.7%开源软件介绍(OpenSource Introduction):iPiciPic could automatically upload images and save Markdown links on macOS.
Download iPic and have a try. iPicUploaderiPic opens the ability to upload images. It means if your App also needs to upload images, no need to build from scratch. Just use iPicUploader, your App could also upload images to Imgur, Flickr, Amazon S3 and other image hosts. iPicUploader UsageUpload image file: let imageFilePath = "/Path/to/the/pic.jpg"
iPic.uploadImage(imageFilePath, handler: { (imageLink, error) in
if let imageLink = imageLink {
// Image uploaded
} else if let error = error {
// Some error happened
}
}) Upload image data: let imageFilePath = "/Path/to/the/pic.jpg"
let imageURL = URL(fileURLWithPath: imageFilePath)
let imageData = try! Data(contentsOf: imageURL)
iPic.uploadImage(imageData, handler: { (imageLink, error) in
if let imageLink = imageLink {
// Image uploaded
} else if let error = error {
// Some error happened
}
})
Upload NSImage: let imageFilePath = "/Path/to/the/pic.jpg"
let image = NSImage(contentsOfFile: imageFilePath)
iPic.uploadImage(image, handler: { (imageLink, error) in
if let imageLink = imageLink {
// Image uploaded
} else if let error = error {
// Some error happened
}
})
iPicUploader ExampleiPicUploader also includes a full example. You will feel easy to start. To run the example project, just clone current repository and open iPicUploader.xcworkspace. Note:
Now, let's have a look how the example upload images. 1. Upload Images by Drag & DropAs you can see, iPicUploader supports upload of multiple images at a time. 2. Upload Images by Select Images Files3. Upload Images by Copy Image and PasteBeside copy image files, you can also copy the image in other Apps to upload. Apps Using iPicUploaderIt would be great to show your apps using iPicUploader here. Pull requests welcome :) RequirementsAs iPic runs on macOS 10.11 and newer version, iPicUploader also needs macOS 10.11+ InstallationiPicUploader is available through CocoaPods. To install it, simply add the following line to your Podfile: pod "iPicUploader" LicenseiPicUploader is available under the MIT license. |
2023-10-27
2022-08-15
2022-08-17
2022-09-23
2022-08-13
请发表评论