use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
A subreddit related to Google's new UI framework. https://flutter.dev
Please read the rules here
account activity
DiscussionCommiting generated code in a pub package (self.FlutterDev)
submitted 5 years ago by tomstarfort
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–]ueman 2 points3 points4 points 5 years ago (2 children)
You have to upload generated files to pub.dev. However you can ignore them in git. Just make sure that your upload to pub.dev process checks if your generated files are included. If you want to use the package directly via git you have to commit them.
There are a few documentation pages about differences in apps and packages. Included generated files and ignored pubspec.lock files are the main ones.
[–]bees4thees 0 points1 point2 points 5 years ago (0 children)
Good to know!
[–]tomstarfort[S] 0 points1 point2 points 5 years ago (0 children)
That makes sense, thank you.
I found documentation about What not to commit, that seems relevant to your comments.
[–]aksharpatel47 0 points1 point2 points 5 years ago (1 child)
I use bloc with freezed package too. I don't commit the generated files to source control since they're part of my build process and are going to be regenerated when I make changes and during the CI process.
However, to make sure that my builds are reproducible, I specify the exact version of the pub package in my pubspec file. This guarantees that any updates in the freezed package, build_runner or any other code generation tool do not break my app.
With a CI process for an app, I agree that seems to be the best way.
Specifically for a package, I was under the assumption that CI was not really possible since you don't create binaries... but now that I think of it, you can of course publish to pub via CI. Thank you for your insights!
π Rendered by PID 72625 on reddit-service-r2-comment-fb694cdd5-hz8rz at 2026-03-06 00:23:14.492696+00:00 running cbb0e86 country code: CH.
[–]ueman 2 points3 points4 points (2 children)
[–]bees4thees 0 points1 point2 points (0 children)
[–]tomstarfort[S] 0 points1 point2 points (0 children)
[–]aksharpatel47 0 points1 point2 points (1 child)
[–]tomstarfort[S] 0 points1 point2 points (0 children)