Summary: | Add --tablename option to misc/devel/update_dbix_class_files.pl script | ||
---|---|---|---|
Product: | Koha | Reporter: | Alex Arnaud <alex.arnaud> |
Component: | Command-line Utilities | Assignee: | Alex Arnaud <alex.arnaud> |
Status: | Failed QA --- | QA Contact: | Marcel de Rooy <m.de.rooy> |
Severity: | enhancement | ||
Priority: | P5 - low | CC: | jonathan.druart, m.de.rooy, olli-antti.kivilahti, robin |
Version: | Main | ||
Hardware: | All | ||
OS: | All | ||
GIT URL: | Change sponsored?: | --- | |
Patch complexity: | --- | Documentation contact: | |
Documentation submission: | Text to go in the release notes: | ||
Version(s) released in: | Circulation function: | ||
Bug Depends on: | |||
Bug Blocks: | 18229 | ||
Attachments: |
Bug 18000 - Add --tablename option to misc/devel/update_dbix_class_files.pl script
Bug 18000 - Add --tablename option to misc/devel/update_dbix_class_files.pl script Bug 18000 - Add --tablename option to misc/devel/update_dbix_class_files.pl script |
Description
Alex Arnaud
2017-01-26 14:36:42 UTC
Created attachment 59584 [details] [review] Bug 18000 - Add --tablename option to misc/devel/update_dbix_class_files.pl script Created attachment 59585 [details] [review] Bug 18000 - Add --tablename option to misc/devel/update_dbix_class_files.pl script I think this is fixed in new version of DBIx::Class::Schema::Loader, I have 0.07042 (In reply to Jonathan Druart from comment #3) > I think this is fixed in new version of DBIx::Class::Schema::Loader, I have > 0.07042 Tested with version 0.07046 and it's better but i still got about thirty files modified. I keep thinking this feature could be nice to avoid that. It would be good to pass several tables. It seems that we can pass a regexp, so I tried: --tablename='*borro*' And got: \A* matches null string many times in regex; marked by <-- HERE in m/\A* <-- HERE borro*\z/ at misc/devel/update_dbix_class_files.pl line 59. Created attachment 60919 [details] [review] Bug 18000 - Add --tablename option to misc/devel/update_dbix_class_files.pl script Signed-off-by: Olli-Antti Kivilahti <olli-antti.kivilahti@jns.fi> Makes life working with DBIx::Class less miserable. perl misc/devel/update_dbix_class_files.pl --tablename issuingrules Works as advertised. This is a much needed improvement. Typically we only alter one table at a time so multiple table updating is not very important for most developers. If you are a RM, you prolly use this without --tablename. See Bug 18229 to make this even more approachable. This does not seem to work. I tested table virtualshelves (added a column). The results between running with table only and on the whole db are different. If you run only on one table, you loose has_many and belongs_to etc. Seems quite dangerous.. |