[Bug 18000] New: Add --tablename option to misc/devel/ update_dbix_class_files.pl script
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=18000 Bug ID: 18000 Summary: Add --tablename option to misc/devel/update_dbix_class_files.pl script Change sponsored?: --- Product: Koha Version: master Hardware: All OS: All Status: NEW Severity: enhancement Priority: P5 - low Component: Command-line Utilities Assignee: gmcharlt@gmail.com Reporter: alex.arnaud@biblibre.com QA Contact: testopia@bugs.koha-community.org CC: robin@catalyst.net.nz Developers, Don't you think it's quite disturbing to see that all Koha schema files appear as modified in your git status when you ran update_dbix_class_files.pl script to get the one related to the table you've just created ? If yes, here is a patch that add the ability to specify a table name to this script, so test and sign. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=18000 --- Comment #1 from Alex Arnaud <alex.arnaud@biblibre.com> --- Created attachment 59584 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=59584&action=edit Bug 18000 - Add --tablename option to misc/devel/update_dbix_class_files.pl script -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=18000 Alex Arnaud <alex.arnaud@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #59584|0 |1 is obsolete| | --- Comment #2 from Alex Arnaud <alex.arnaud@biblibre.com> --- Created attachment 59585 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=59585&action=edit Bug 18000 - Add --tablename option to misc/devel/update_dbix_class_files.pl script -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=18000 Alex Arnaud <alex.arnaud@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |Needs Signoff -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=18000 Alex Arnaud <alex.arnaud@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|gmcharlt@gmail.com |alex.arnaud@biblibre.com QA Contact|testopia@bugs.koha-communit |alex.arnaud@biblibre.com |y.org | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=18000 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |jonathan.druart@bugs.koha-c | |ommunity.org --- Comment #3 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- I think this is fixed in new version of DBIx::Class::Schema::Loader, I have 0.07042 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=18000 --- Comment #4 from Alex Arnaud <alex.arnaud@biblibre.com> --- (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. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=18000 --- Comment #5 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- 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. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=18000 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- QA Contact|alex.arnaud@biblibre.com | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=18000 Olli-Antti Kivilahti <olli-antti.kivilahti@jns.fi> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #59585|0 |1 is obsolete| | --- Comment #6 from Olli-Antti Kivilahti <olli-antti.kivilahti@jns.fi> --- Created attachment 60919 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=60919&action=edit 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. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=18000 Olli-Antti Kivilahti <olli-antti.kivilahti@jns.fi> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |olli-antti.kivilahti@jns.fi Status|Needs Signoff |Signed Off --- Comment #7 from Olli-Antti Kivilahti <olli-antti.kivilahti@jns.fi> --- 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. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=18000 Olli-Antti Kivilahti <olli-antti.kivilahti@jns.fi> changed: What |Removed |Added ---------------------------------------------------------------------------- Blocks| |18229 Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=18229 [Bug 18229] update_dbix_class_files.pl loads defaults from ~/.my.cnf -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=18000 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |m.de.rooy@rijksmuseum.nl QA Contact| |m.de.rooy@rijksmuseum.nl -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=18000 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Failed QA --- Comment #8 from Marcel de Rooy <m.de.rooy@rijksmuseum.nl> --- 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.. -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org