Commit Graph

16 Commits

Author SHA1 Message Date
Joey Tepperman 3b8f55b3d1
Fix `create_versions` migration to support Ruby3 (#1366)
* Fix `create_versions` migration to support Ruby3

* Update changelog
2022-03-09 17:09:46 -05:00
Nuzair Rasheed 81f935fb79
Added ability to set uuid as item_id type while generating migration (#1374)
* Added ability to set uuid as item_id type while generating migration

* added changelog

* changed uuid to string

* Revert "added changelog"

This reverts commit 47b074e144.

* Made suggested changed

* Added changelog

* Updated readme with installation instructions.

* Added fixed issue to changelog
2022-03-09 12:59:19 -05:00
Renan Gurgel 212b145a1f
Fix 'rails db:migrate' error when run against an app with mysql2 adapter (#1298) 2021-03-26 10:38:21 -04:00
Jared Beck de1dda4f79 Remove vestigial version conditionals 2021-03-21 01:07:08 -04:00
Nic Boie f7fe9cfd1e Change install generator to use new hash syntax
The install generator used literal Ruby hashes to build options for the
item_type field.  This change modifies the generator to use string
literal output, which is consistent with the other option building method
in the generator.

Co-authored-by: Jared Beck <jared@jaredbeck.com>
2021-01-21 10:28:14 -05:00
Utkarsh Gupta a2bc1b6eb4 Use RuboCop::Packaging amongst other extensions
And also fix the offenses shown by the respective cops.
The docs can be found here:
https://docs.rubocop.org/rubocop-packaging/cops_packaging.html

Signed-off-by: Utkarsh Gupta <utkarsh@debian.org>
2020-12-31 23:57:10 +05:30
lorint e8a6096aa2 Generator to update historic item_subtype entries (#1144)
* Generator to update historic item_subtype entries

* Simpler migrations for Foo and Bar test databases

* Rubocop indentation
2018-08-26 21:25:16 -04:00
Jared Beck 9f004a60e0 Revert #1108 (lorint's STI fix)
This partially reverts commit 58369e1d8f.
I have kept the specs, skipped.

Per the following, this approach does not seem to be working:

- https://github.com/paper-trail-gem/paper_trail/issues/1135
- https://github.com/paper-trail-gem/paper_trail/pull/1137
- https://github.com/seanlinsley/paper_trail/pull/1
2018-08-21 23:13:34 -04:00
lorint 58369e1d8f Fix for issue #594, reifying sub-classed models that use STI (#1108)
See the changes to the changelog and readme for details.
2018-07-30 10:50:32 -04:00
Jared Beck c0633be405 Lint: Style/ExpandPathArguments 2018-03-27 18:32:52 -04:00
Jared Beck cfbf7a647c Lint: Style/FrozenStringLiteralComment 2017-12-10 23:05:39 -05:00
Jared Beck c2d5df8fde Lint: RSpec/BeforeAfterAll 2017-11-30 22:17:42 -05:00
Jared Beck 1af1d0dab0 Lint: Fix RSpec/FilePath 2017-10-17 18:37:43 -04:00
Jared Beck f92cfbc23d Inherit from the new versioned migration class
e.g. `ActiveRecord::Migration[5.1]`

Fixes #949

Following the example of the devise gem, use erb. In addition, add
the `.erb` file extension to fix syntax highlighting in editor.

Deletes create_versions_spec.rb because the file is no longer valid
ruby so those tests will have to be re-written. We can either
generate a valid ruby file and continue to use similar assertions,
or we can convert those features to use erb, which will have the
benefit of cleaner generated files.
2017-04-10 11:10:15 -04:00
Jared Beck 0435936a37 Set MySQL collation: versions tbl: utf8mb4_general_ci
Should fix the "Unknown collation: 'utf8mb4_col'" error from
https://github.com/airblade/paper_trail/issues/741
2016-03-31 16:24:11 -04:00
Jared Beck d138b955af MySQL: Specify utf8mb4 charset for versions table
Fixes #651
2015-12-27 17:59:20 -05:00