This is a plane Dart script, that is obfuscating dart projects, including flutter
Obfuscator will go under /lib directory and obfuscate all files except exported once. It's dedicated for libraries, packages and SDKs that should be distributed without revealing source code to the client.
- Determine which files should not be obfuscated (the once under lib and once mentioned in export notation) and which should - the rest.
- Move all source code to singe file and delete rest of files
- Obfuscate resulting source code
- Make sure you can run dart scripts, see https://dart.dev/tutorials/server/get-started
- Ensure you have all changes in your repository saved, script will delete all files ???
- Make sure your project is compilable and runnable, all the generatable files are generated.
- Run console command:
dart lib/main.dart "path/to/your/flutter-project" -o "output_file_name" //todo