Skip to content

Commit

Permalink
Updated MacOS saveAs() support, Updated Readme for new discord button
Browse files Browse the repository at this point in the history
  • Loading branch information
incrediblezayed committed Aug 7, 2023
1 parent 3ceb4eb commit bd2e136
Show file tree
Hide file tree
Showing 5 changed files with 30 additions and 28 deletions.
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@

All notable changes to this project will be documented in this file.

## [0.2.8]
* Moving saveAs() support for macOS to production.

## [0.2.7]
* Updated the http package to the latest version (issue [#63](https://github.com/incrediblezayed/file_saver/issues/63))

Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# FileSaver
[![Discord](https://www.incrediblezayed.com/file_saver_discord.png)](https://discord.gg/4yRFt68kty)
[![Discord](https://www.hassanansari.dev/public/file_saver_discord.png)](https://discord.gg/4yRFt68kty)


This plugin package is not much but only for saving files in Android, iOS, Web, Windows, MacOS and Linux. The package
Expand Down Expand Up @@ -48,7 +48,7 @@ type
MimeType is also included in my Package, I've included types for **Sheets, Presentation, Word, Plain Text, PDF,
MP3, MP4 and many other common formats**

or you can call saveAs() _only available for android and iOS at the moment_
or you can call saveAs() _only available for android and iOS & macOS at the moment_

```dart
await FileSaver.instance.saveAs({
Expand Down
6 changes: 3 additions & 3 deletions example/macos/Podfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -9,20 +9,20 @@ PODS:
DEPENDENCIES:
- file_saver (from `Flutter/ephemeral/.symlinks/plugins/file_saver/macos`)
- FlutterMacOS (from `Flutter/ephemeral`)
- path_provider_foundation (from `Flutter/ephemeral/.symlinks/plugins/path_provider_foundation/macos`)
- path_provider_foundation (from `Flutter/ephemeral/.symlinks/plugins/path_provider_foundation/darwin`)

EXTERNAL SOURCES:
file_saver:
:path: Flutter/ephemeral/.symlinks/plugins/file_saver/macos
FlutterMacOS:
:path: Flutter/ephemeral
path_provider_foundation:
:path: Flutter/ephemeral/.symlinks/plugins/path_provider_foundation/macos
:path: Flutter/ephemeral/.symlinks/plugins/path_provider_foundation/darwin

SPEC CHECKSUMS:
file_saver: 44e6fbf666677faf097302460e214e977fdd977b
FlutterMacOS: 8f6f14fa908a6fb3fba0cd85dbd81ec4b251fb24
path_provider_foundation: c68054786f1b4f3343858c1e1d0caaded73f0be9
path_provider_foundation: 29f094ae23ebbca9d3d0cec13889cd9060c0e943

PODFILE CHECKSUM: 353c8bcc5d5b0994e508d035b5431cfe18c1dea7

Expand Down
42 changes: 21 additions & 21 deletions example/macos/Runner/DebugProfile.entitlements
Original file line number Diff line number Diff line change
@@ -1,24 +1,24 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>com.apple.security.app-sandbox</key>
<true/>
<key>com.apple.security.assets.movies.read-write</key>
<true/>
<key>com.apple.security.assets.music.read-write</key>
<true/>
<key>com.apple.security.assets.pictures.read-write</key>
<true/>
<key>com.apple.security.cs.allow-jit</key>
<true/>
<key>com.apple.security.files.downloads.read-write</key>
<true/>
<key>com.apple.security.files.user-selected.read-write</key>
<true/>
<key>com.apple.security.network.server</key>
<true/>
<key>com.apple.security.network.client</key>
<true/>
</dict>
</plist>
<dict>
<key>com.apple.security.app-sandbox</key>
<true />
<key>com.apple.security.assets.movies.read-write</key>
<true />
<key>com.apple.security.assets.music.read-write</key>
<true />
<key>com.apple.security.assets.pictures.read-write</key>
<true />
<key>com.apple.security.files.downloads.read-write</key>
<true />
<key>com.apple.security.files.user-selected.read-write</key>
<true />
<key>com.apple.security.network.server</key>
<true />
<key>com.apple.security.network.client</key>
<true />
<key>com.apple.security.cs.allow-jit</key>
<true />
</dict>
</plist>
3 changes: 1 addition & 2 deletions lib/file_saver.dart
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ class FileSaver {
}
}

///[saveAs] This method will open a Save As File dialog where user can select the location for saving file.
/// [saveAs] This method will open a Save As File dialog where user can select the location for saving file.
///
/// [name]: Name of your file.
///
Expand All @@ -102,7 +102,6 @@ class FileSaver {
///
/// mimeType (Mainly required for web): MimeType from enum MimeType..
///
/// More Mimetypes will be added in future
Future<String?> saveAs({
required String name,
Uint8List? bytes,
Expand Down

0 comments on commit bd2e136

Please sign in to comment.