diff-lcs 2.0.0.beta.2 → 2.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +173 -86
- data/CODE_OF_CONDUCT.md +155 -116
- data/CONTRIBUTING.md +29 -28
- data/CONTRIBUTORS.md +15 -11
- data/LICENCE.md +19 -38
- data/Manifest.txt +16 -3
- data/README.md +37 -26
- data/Rakefile +3 -0
- data/SECURITY.md +7 -7
- data/lib/diff/lcs/array.rb +3 -1
- data/lib/diff/lcs/callbacks.rb +1 -1
- data/lib/diff/lcs/change.rb +74 -32
- data/lib/diff/lcs/frozen_value.rb +74 -0
- data/lib/diff/lcs/hunk.rb +146 -58
- data/lib/diff/lcs/internals.rb +183 -72
- data/lib/diff/lcs/ldiff.rb +23 -45
- data/lib/diff/lcs/string.rb +3 -1
- data/lib/diff/lcs/version.rb +1 -1
- data/lib/diff/lcs.rb +29 -26
- data/licences/MIT.txt +19 -0
- data/spec/ldiff_spec.rb +9 -7
- data/test/fixtures/ldiff/output.diff.bin1-q +0 -0
- data/test/fixtures/ldiff/output.diff.bin2-q +1 -0
- data/test/fixtures/ldiff/output.diff.hunks +9 -0
- data/test/fixtures/ldiff/output.diff.hunks-c +35 -0
- data/test/fixtures/ldiff/output.diff.hunks-u +20 -0
- data/test/fixtures/ldiff/output.diff.same +0 -0
- data/test/fixtures/ldiff/output.diff.same-c +0 -0
- data/test/fixtures/ldiff/output.diff.same-u +0 -0
- data/test/fixtures/new-hunks +31 -0
- data/test/fixtures/old-hunks +30 -0
- data/test/test_change.rb +23 -19
- data/test/test_frozen_value.rb +155 -0
- data/test/test_helper.rb +5 -0
- data/test/test_hunk.rb +238 -0
- data/test/test_lcs.rb +147 -0
- data/test/test_ldiff.rb +64 -7
- metadata +28 -18
- /data/{licenses → licences}/COPYING.txt +0 -0
- /data/{licenses → licences}/artistic.txt +0 -0
- /data/{licenses → licences}/dco.txt +0 -0
data/CODE_OF_CONDUCT.md
CHANGED
|
@@ -1,128 +1,167 @@
|
|
|
1
|
-
# Contributor Covenant Code of Conduct
|
|
1
|
+
# Contributor Covenant 3.0 Code of Conduct
|
|
2
2
|
|
|
3
3
|
## Our Pledge
|
|
4
4
|
|
|
5
|
-
We
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
identity
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
or
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
5
|
+
We pledge to make our community welcoming, safe, and equitable for all.
|
|
6
|
+
|
|
7
|
+
We are committed to fostering an environment that respects and promotes the
|
|
8
|
+
dignity, rights, and contributions of all individuals, regardless of
|
|
9
|
+
characteristics including race, ethnicity, caste, color, age, physical
|
|
10
|
+
characteristics, neurodiversity, disability, sex or gender, gender identity or
|
|
11
|
+
expression, sexual orientation, language, philosophy or religion, national or
|
|
12
|
+
social origin, socio-economic position, level of education, or other status.
|
|
13
|
+
The same privileges of participation are extended to everyone who participates
|
|
14
|
+
in good faith and in accordance with this Covenant.
|
|
15
|
+
|
|
16
|
+
## Encouraged Behaviors
|
|
17
|
+
|
|
18
|
+
While acknowledging differences in social norms, we all strive to meet our
|
|
19
|
+
community's expectations for positive behavior. We also understand that our
|
|
20
|
+
words and actions may be interpreted differently than we intend based on
|
|
21
|
+
culture, background, or native language.
|
|
22
|
+
|
|
23
|
+
With these considerations in mind, we agree to behave mindfully toward each
|
|
24
|
+
other and act in ways that center our shared values, including:
|
|
25
|
+
|
|
26
|
+
1. Respecting the **purpose of our community**, our activities, and our ways
|
|
27
|
+
of gathering.
|
|
28
|
+
2. Engaging **kindly and honestly** with others.
|
|
29
|
+
3. Respecting **different viewpoints** and experiences.
|
|
30
|
+
4. **Taking responsibility** for our actions and contributions.
|
|
31
|
+
5. Gracefully giving and accepting **constructive feedback**.
|
|
32
|
+
6. Committing to **repairing harm** when it occurs.
|
|
33
|
+
7. Behaving in other ways that promote and sustain the **well-being of our
|
|
34
|
+
community**.
|
|
35
|
+
|
|
36
|
+
## Restricted Behaviors
|
|
37
|
+
|
|
38
|
+
We agree to restrict the following behaviors in our community. Instances,
|
|
39
|
+
threats, and promotion of these behaviors are violations of this Code of
|
|
40
|
+
Conduct.
|
|
41
|
+
|
|
42
|
+
1. **Harassment.** Violating explicitly expressed boundaries or engaging in
|
|
43
|
+
unnecessary personal attention after any clear request to stop.
|
|
44
|
+
2. **Character attacks.** Making insulting, demeaning, or pejorative comments
|
|
45
|
+
directed at a community member or group of people.
|
|
46
|
+
3. **Stereotyping or discrimination.** Characterizing anyone's personality or
|
|
47
|
+
behavior on the basis of immutable identities or traits.
|
|
48
|
+
4. **Sexualization.** Behaving in a way that would generally be considered
|
|
49
|
+
inappropriately intimate in the context or purpose of the community.
|
|
50
|
+
5. **Violating confidentiality**. Sharing or acting on someone's personal or
|
|
51
|
+
private information without their permission.
|
|
52
|
+
6. **Endangerment.** Causing, encouraging, or threatening violence or other
|
|
53
|
+
harm toward any person or group.
|
|
54
|
+
7. Behaving in other ways that **threaten the well-being** of our community.
|
|
55
|
+
|
|
56
|
+
### Other Restrictions
|
|
57
|
+
|
|
58
|
+
1. **Misleading identity.** Impersonating someone else for any reason, or
|
|
59
|
+
pretending to be someone else to evade enforcement actions.
|
|
60
|
+
2. **Failing to credit sources.** Not properly crediting the sources of
|
|
61
|
+
content you contribute.
|
|
62
|
+
3. **Promotional materials**. Sharing marketing or other commercial content in
|
|
63
|
+
a way that is outside the norms of the community.
|
|
64
|
+
4. **Irresponsible communication.** Failing to responsibly present content
|
|
65
|
+
which includes, links or describes any other restricted behaviors.
|
|
66
|
+
|
|
67
|
+
## Reporting an Issue
|
|
68
|
+
|
|
69
|
+
Tensions can occur between community members even when they are trying their
|
|
70
|
+
best to collaborate. Not every conflict represents a code of conduct
|
|
71
|
+
violation, and this Code of Conduct reinforces encouraged behaviors and norms
|
|
72
|
+
that can help avoid conflicts and minimize harm.
|
|
73
|
+
|
|
74
|
+
When an incident does occur, it is important to report it promptly. To report
|
|
75
|
+
a possible violation, create a [private security advisory][advisory] —
|
|
76
|
+
violations of this code of conduct are considered security vulnerabilities.
|
|
77
|
+
|
|
78
|
+
Community Moderators take reports of violations seriously and will make every
|
|
79
|
+
effort to respond in a timely manner. They will investigate all reports of
|
|
80
|
+
code of conduct violations, reviewing messages, logs, and recordings, or
|
|
81
|
+
interviewing witnesses and other participants. Community Moderators will keep
|
|
82
|
+
investigation and enforcement actions as transparent as possible while
|
|
83
|
+
prioritizing safety and confidentiality. In order to honor these values,
|
|
84
|
+
enforcement actions are carried out in private with the involved parties, but
|
|
85
|
+
communicating to the whole community may be part of a mutually agreed upon
|
|
86
|
+
resolution.
|
|
87
|
+
|
|
88
|
+
## Addressing and Repairing Harm
|
|
89
|
+
|
|
90
|
+
If an investigation by the Community Moderators finds that this Code of
|
|
91
|
+
Conduct has been violated, the following enforcement ladder may be used to
|
|
92
|
+
determine how best to repair harm, based on the incident's impact on the
|
|
93
|
+
individuals involved and the community as a whole. Depending on the severity
|
|
94
|
+
of a violation, lower rungs on the ladder may be skipped.
|
|
95
|
+
|
|
96
|
+
1. Warning
|
|
97
|
+
1. Event: A violation involving a single incident or series of incidents.
|
|
98
|
+
2. Consequence: A private, written warning from the Community Moderators.
|
|
99
|
+
3. Repair: Examples of repair include a private written apology,
|
|
100
|
+
acknowledgement of responsibility, and seeking clarification on
|
|
101
|
+
expectations.
|
|
102
|
+
|
|
103
|
+
2. Temporarily Limited Activities
|
|
104
|
+
1. Event: A repeated incidence of a violation that previously resulted in a
|
|
105
|
+
warning, or the first incidence of a more serious violation.
|
|
106
|
+
2. Consequence: A private, written warning with a time-limited cooldown
|
|
107
|
+
period designed to underscore the seriousness of the situation and give
|
|
108
|
+
the community members involved time to process the incident. The
|
|
109
|
+
cooldown period may be limited to particular communication channels or
|
|
110
|
+
interactions with particular community members.
|
|
111
|
+
3. Repair: Examples of repair may include making an apology, using the
|
|
112
|
+
cooldown period to reflect on actions and impact, and being thoughtful
|
|
113
|
+
about re-entering community spaces after the period is over.
|
|
114
|
+
|
|
115
|
+
3. Temporary Suspension
|
|
116
|
+
1. Event: A pattern of repeated violation which the Community Moderators
|
|
117
|
+
have tried to address with warnings, or a single serious violation.
|
|
118
|
+
2. Consequence: A private written warning with conditions for return from
|
|
119
|
+
suspension. In general, temporary suspensions give the person being
|
|
120
|
+
suspended time to reflect upon their behavior and possible corrective
|
|
121
|
+
actions.
|
|
122
|
+
3. Repair: Examples of repair include respecting the spirit of the
|
|
123
|
+
suspension, meeting the specified conditions for return, and being
|
|
124
|
+
thoughtful about how to reintegrate with the community when the
|
|
125
|
+
suspension is lifted.
|
|
126
|
+
|
|
127
|
+
4. Permanent Ban
|
|
128
|
+
1. Event: A pattern of repeated code of conduct violations that other steps
|
|
129
|
+
on the ladder have failed to resolve, or a violation so serious that the
|
|
130
|
+
Community Moderators determine there is no way to keep the community
|
|
131
|
+
safe with this person as a member.
|
|
132
|
+
2. Consequence: Access to all community spaces, tools, and communication
|
|
133
|
+
channels is removed. In general, permanent bans should be rarely used,
|
|
134
|
+
should have strong reasoning behind them, and should only be resorted to
|
|
135
|
+
if working through other remedies has failed to change the behavior.
|
|
136
|
+
3. Repair: There is no possible repair in cases of this severity.
|
|
137
|
+
|
|
138
|
+
This enforcement ladder is intended as a guideline. It does not limit the
|
|
139
|
+
ability of Community Managers to use their discretion and judgment, in keeping
|
|
140
|
+
with the best interests of our community.
|
|
50
141
|
|
|
51
142
|
## Scope
|
|
52
143
|
|
|
53
|
-
This Code of Conduct applies within all community spaces, and also applies
|
|
54
|
-
an individual is officially representing the community in public
|
|
55
|
-
Examples of representing our community include using an official email
|
|
56
|
-
posting via an official social media account, or acting as an
|
|
57
|
-
representative at an online or offline event.
|
|
58
|
-
|
|
59
|
-
## Enforcement
|
|
60
|
-
|
|
61
|
-
Instances of abusive, harassing, or otherwise unacceptable behavior may be
|
|
62
|
-
reported to the community leaders responsible for enforcement at [INSERT CONTACT
|
|
63
|
-
METHOD]. All complaints will be reviewed and investigated promptly and fairly.
|
|
64
|
-
|
|
65
|
-
All community leaders are obligated to respect the privacy and security of the
|
|
66
|
-
reporter of any incident.
|
|
67
|
-
|
|
68
|
-
## Enforcement Guidelines
|
|
69
|
-
|
|
70
|
-
Community leaders will follow these Community Impact Guidelines in determining
|
|
71
|
-
the consequences for any action they deem in violation of this Code of Conduct:
|
|
72
|
-
|
|
73
|
-
### 1. Correction
|
|
74
|
-
|
|
75
|
-
**Community Impact**: Use of inappropriate language or other behavior deemed
|
|
76
|
-
unprofessional or unwelcome in the community.
|
|
77
|
-
|
|
78
|
-
**Consequence**: A private, written warning from community leaders, providing
|
|
79
|
-
clarity around the nature of the violation and an explanation of why the
|
|
80
|
-
behavior was inappropriate. A public apology may be requested.
|
|
81
|
-
|
|
82
|
-
### 2. Warning
|
|
83
|
-
|
|
84
|
-
**Community Impact**: A violation through a single incident or series of
|
|
85
|
-
actions.
|
|
86
|
-
|
|
87
|
-
**Consequence**: A warning with consequences for continued behavior. No
|
|
88
|
-
interaction with the people involved, including unsolicited interaction with
|
|
89
|
-
those enforcing the Code of Conduct, for a specified period of time. This
|
|
90
|
-
includes avoiding interactions in community spaces as well as external channels
|
|
91
|
-
like social media. Violating these terms may lead to a temporary or permanent
|
|
92
|
-
ban.
|
|
93
|
-
|
|
94
|
-
### 3. Temporary Ban
|
|
95
|
-
|
|
96
|
-
**Community Impact**: A serious violation of community standards, including
|
|
97
|
-
sustained inappropriate behavior.
|
|
98
|
-
|
|
99
|
-
**Consequence**: A temporary ban from any sort of interaction or public
|
|
100
|
-
communication with the community for a specified period of time. No public or
|
|
101
|
-
private interaction with the people involved, including unsolicited interaction
|
|
102
|
-
with those enforcing the Code of Conduct, is allowed during this period.
|
|
103
|
-
Violating these terms may lead to a permanent ban.
|
|
104
|
-
|
|
105
|
-
### 4. Permanent Ban
|
|
106
|
-
|
|
107
|
-
**Community Impact**: Demonstrating a pattern of violation of community
|
|
108
|
-
standards, including sustained inappropriate behavior, harassment of an
|
|
109
|
-
individual, or aggression toward or disparagement of classes of individuals.
|
|
110
|
-
|
|
111
|
-
**Consequence**: A permanent ban from any sort of public interaction within the
|
|
112
|
-
community.
|
|
144
|
+
This Code of Conduct applies within all community spaces, and also applies
|
|
145
|
+
when an individual is officially representing the community in public or other
|
|
146
|
+
spaces. Examples of representing our community include using an official email
|
|
147
|
+
address, posting via an official social media account, or acting as an
|
|
148
|
+
appointed representative at an online or offline event.
|
|
113
149
|
|
|
114
150
|
## Attribution
|
|
115
151
|
|
|
116
|
-
This Code of Conduct is adapted from the
|
|
117
|
-
|
|
118
|
-
<https://www.contributor-covenant.org/version/2/1/code_of_conduct.html>.
|
|
152
|
+
This Code of Conduct is adapted from the Contributor Covenant, version 3.0,
|
|
153
|
+
permanently available at <https://www.contributor-covenant.org/version/3/0/>.
|
|
119
154
|
|
|
120
|
-
|
|
121
|
-
|
|
155
|
+
Contributor Covenant is stewarded by the Organization for Ethical Source and
|
|
156
|
+
licensed under CC BY-SA 4.0. To view a copy of this license, visit
|
|
157
|
+
<https://creativecommons.org/licenses/by-sa/4.0/>.
|
|
122
158
|
|
|
123
|
-
For answers to common questions about
|
|
124
|
-
<https://www.contributor-covenant.org/faq>. Translations are
|
|
125
|
-
<https://www.contributor-covenant.org/translations>.
|
|
159
|
+
For answers to common questions about Contributor Covenant, see the FAQ at
|
|
160
|
+
<https://www.contributor-covenant.org/faq>. Translations are provided at
|
|
161
|
+
<https://www.contributor-covenant.org/translations>. Additional enforcement
|
|
162
|
+
and community guideline resources can be found at
|
|
163
|
+
<https://www.contributor-covenant.org/resources>. The enforcement ladder was
|
|
164
|
+
inspired by the work of [Mozilla's code of conduct team][inclusion].
|
|
126
165
|
|
|
127
|
-
[
|
|
128
|
-
[
|
|
166
|
+
[advisory]: https://github.com/halostatue/diff-lcs/security/advisories/new
|
|
167
|
+
[inclusion]: https://github.com/mozilla/inclusion
|
data/CONTRIBUTING.md
CHANGED
|
@@ -4,7 +4,7 @@ Contribution to diff-lcs is encouraged: bug reports, feature requests, or code
|
|
|
4
4
|
contributions. New features should be proposed and discussed in an
|
|
5
5
|
[issue][issues].
|
|
6
6
|
|
|
7
|
-
Before contributing patches, please read the [Licence](
|
|
7
|
+
Before contributing patches, please read the [Licence](LICENCE.md).
|
|
8
8
|
|
|
9
9
|
diff-lcs is governed under the [Contributor Covenant Code of Conduct][cccoc].
|
|
10
10
|
|
|
@@ -15,29 +15,29 @@ I have several guidelines to contributing code through pull requests:
|
|
|
15
15
|
- All code changes require tests. In most cases, this will be added or updated
|
|
16
16
|
unit tests. I use [Minitest][minitest].
|
|
17
17
|
|
|
18
|
-
- There are integration tests with RSpec which must not be broken,
|
|
19
|
-
through `rake integration`. This requires a non-bundled RSpec,
|
|
18
|
+
- There are integration tests with RSpec which must not be broken,
|
|
19
|
+
accessible through `rake integration`. This requires a non-bundled RSpec,
|
|
20
20
|
`gem install rspec`.
|
|
21
21
|
|
|
22
|
-
- I use code formatters, static analysis tools, and linting to ensure
|
|
23
|
-
styles and formatting. There should be no warning output from
|
|
24
|
-
processes. I use [Standard Ruby][standardrb].
|
|
22
|
+
- I use code formatters, static analysis tools, and linting to ensure
|
|
23
|
+
consistent styles and formatting. There should be no warning output from
|
|
24
|
+
test run processes. I use [Standard Ruby][standardrb].
|
|
25
25
|
|
|
26
|
-
- Proposed changes should be on a thoughtfully-named topic branch and
|
|
27
|
-
into logical commit chunks as appropriate.
|
|
26
|
+
- Proposed changes should be on a thoughtfully-named topic branch and
|
|
27
|
+
organized into logical commit chunks as appropriate.
|
|
28
28
|
|
|
29
29
|
- Use [Conventional Commits][conventional] with my
|
|
30
30
|
[conventions](#commit-conventions).
|
|
31
31
|
|
|
32
|
-
- Versions must not be updated in pull requests unless otherwise directed.
|
|
33
|
-
means that you must not:
|
|
32
|
+
- Versions must not be updated in pull requests unless otherwise directed.
|
|
33
|
+
This means that you must not:
|
|
34
34
|
|
|
35
35
|
- Modify `VERSION` in `lib/diff/lcs/version.rb`. When your patch is accepted
|
|
36
36
|
and a release is made, the version will be updated at that point.
|
|
37
37
|
|
|
38
38
|
- Modify `diff-lcs.gemspec`; it is a generated file. (You _may_ use
|
|
39
|
-
`rake gemspec` to regenerate it if your change involves metadata related
|
|
40
|
-
gem itself).
|
|
39
|
+
`rake gemspec` to regenerate it if your change involves metadata related
|
|
40
|
+
to gem itself).
|
|
41
41
|
|
|
42
42
|
- Modify the `Gemfile`.
|
|
43
43
|
|
|
@@ -52,7 +52,8 @@ I have several guidelines to contributing code through pull requests:
|
|
|
52
52
|
`CHANGELOG.md` as a separate commit from your main change. (Follow the style
|
|
53
53
|
in the `CHANGELOG.md` and provide a link to your PR.)
|
|
54
54
|
|
|
55
|
-
- Include your DCO sign-off in each commit message (see
|
|
55
|
+
- Include your DCO sign-off in each commit message (see
|
|
56
|
+
[LICENCE](LICENCE.md)).
|
|
56
57
|
|
|
57
58
|
## AI Contribution Policy
|
|
58
59
|
|
|
@@ -62,17 +63,17 @@ sort be well understood by the submitter and that the developer can attest to
|
|
|
62
63
|
the [Developer Certificate of Origin][dco] for each pull request (see
|
|
63
64
|
[LICENCE](LICENCE.md)).
|
|
64
65
|
|
|
65
|
-
Any contribution (bug, feature request, or pull request) that uses undeclared
|
|
66
|
-
output will be rejected.
|
|
66
|
+
Any contribution (bug, feature request, or pull request) that uses undeclared
|
|
67
|
+
AI output will be rejected.
|
|
67
68
|
|
|
68
69
|
## Test Dependencies
|
|
69
70
|
|
|
70
|
-
diff-lcs uses Ryan Davis's [Hoe][Hoe] to manage the release process, and it
|
|
71
|
-
a number of rake tasks. You will mostly be interested in `rake`, which
|
|
72
|
-
tests in the same way that `rake spec` does.
|
|
71
|
+
diff-lcs uses Ryan Davis's [Hoe][Hoe] to manage the release process, and it
|
|
72
|
+
adds a number of rake tasks. You will mostly be interested in `rake`, which
|
|
73
|
+
runs tests in the same way that `rake spec` does.
|
|
73
74
|
|
|
74
|
-
To assist with the installation of the development dependencies for diff-lcs,
|
|
75
|
-
have provided a Gemfile pointing to the (generated) `diff-lcs.gemspec` file.
|
|
75
|
+
To assist with the installation of the development dependencies for diff-lcs,
|
|
76
|
+
I have provided a Gemfile pointing to the (generated) `diff-lcs.gemspec` file.
|
|
76
77
|
This will permit you to use `bundle install` to install the dependencies.
|
|
77
78
|
|
|
78
79
|
You can run tests with code coverage analysis by running `rake spec:coverage`.
|
|
@@ -100,21 +101,21 @@ required metadata trailers are:
|
|
|
100
101
|
- `Breaking-Change`: if the change is a breaking change. **Do not** use the
|
|
101
102
|
shorthand form (`feat!(scope)`) or `BREAKING CHANGE`.
|
|
102
103
|
|
|
103
|
-
- `Signed-off-by`: this is required for all developers except me, as outlined
|
|
104
|
-
the [Licence](
|
|
104
|
+
- `Signed-off-by`: this is required for all developers except me, as outlined
|
|
105
|
+
in the [Licence](LICENCE.md#developer-certificate-of-origin).
|
|
105
106
|
|
|
106
107
|
- `Fixes` or `Resolves`: If a change fixes one or more open [issues][issues],
|
|
107
108
|
that issue must be included in the `Fixes` or `Resolves` trailer. Multiple
|
|
108
109
|
issues should be listed comma separated in the same trailer:
|
|
109
|
-
`Fixes: #1, #5, #7`, but _may_ appear in separate trailers. While both
|
|
110
|
-
and `Resolves` are synonyms, only _one_ should be used in a given
|
|
111
|
-
pull request.
|
|
110
|
+
`Fixes: #1, #5, #7`, but _may_ appear in separate trailers. While both
|
|
111
|
+
`Fixes` and `Resolves` are synonyms, only _one_ should be used in a given
|
|
112
|
+
commit or pull request.
|
|
112
113
|
|
|
113
|
-
- `Related to`: If a change does not fix an issue, those issue references
|
|
114
|
-
be included in this trailer.
|
|
114
|
+
- `Related to`: If a change does not fix an issue, those issue references
|
|
115
|
+
should be included in this trailer.
|
|
115
116
|
|
|
116
117
|
[cbeams]: https://cbea.ms/git-commit/
|
|
117
|
-
[cccoc]:
|
|
118
|
+
[cccoc]: CODE_OF_CONDUCT.md
|
|
118
119
|
[conventional]: https://www.conventionalcommits.org/en/v1.0.0/
|
|
119
120
|
[dco]: licences/dco.txt
|
|
120
121
|
[hoe]: https://github.com/seattlerb/hoe
|
data/CONTRIBUTORS.md
CHANGED
|
@@ -4,19 +4,16 @@
|
|
|
4
4
|
|
|
5
5
|
Thanks to everyone else who has contributed to diff-lcs over the years:
|
|
6
6
|
|
|
7
|
-
- [@ginriki][gh-user-ginriki]
|
|
8
|
-
- [@joshbronson][gh-user-joshbronson]
|
|
9
|
-
- [@kevinmook][gh-user-kevinmook]
|
|
10
|
-
- [@mckaz][gh-user-mckaz]
|
|
11
7
|
- Akinori Musha
|
|
12
8
|
- Artem Ignatyev
|
|
13
|
-
- Brandon Fish
|
|
14
9
|
- Baptiste Courtois ([@annih][gh-user-annih])
|
|
10
|
+
- Brandon Fish
|
|
15
11
|
- Camille Drapier
|
|
16
12
|
- Cédric Boutillier
|
|
17
|
-
- [@
|
|
13
|
+
- Clément Joubert ([@czj][gh-user-czj])
|
|
18
14
|
- Gregg Kellogg
|
|
19
15
|
- Jagdeep Singh
|
|
16
|
+
- James Thompson ([@thompson-tomo][gh-user-thompson-tomo])
|
|
20
17
|
- Jason Gladish
|
|
21
18
|
- Jon Rowe
|
|
22
19
|
- Josef Strzibny
|
|
@@ -29,8 +26,8 @@ Thanks to everyone else who has contributed to diff-lcs over the years:
|
|
|
29
26
|
- Kevin Ansfield
|
|
30
27
|
- Koichi Ito
|
|
31
28
|
- Mark Friedgan
|
|
32
|
-
- Masato Nakamura
|
|
33
29
|
- Mark Young
|
|
30
|
+
- Masato Nakamura
|
|
34
31
|
- Michael Granger
|
|
35
32
|
- Myron Marston
|
|
36
33
|
- Nicolas Leger
|
|
@@ -47,13 +44,20 @@ Thanks to everyone else who has contributed to diff-lcs over the years:
|
|
|
47
44
|
- Tien ([@tiendo1011][gh-user-tiendo1011])
|
|
48
45
|
- Tomas Jura
|
|
49
46
|
- Vít Ondruch
|
|
47
|
+
- [@earlopain][gh-user-earlopain]
|
|
48
|
+
- [@ginriki][gh-user-ginriki]
|
|
49
|
+
- [@joshbronson][gh-user-joshbronson]
|
|
50
|
+
- [@kevinmook][gh-user-kevinmook]
|
|
51
|
+
- [@mckaz][gh-user-mckaz]
|
|
50
52
|
|
|
51
|
-
[gh-user-
|
|
53
|
+
[gh-user-annih]: https://github.com/annih
|
|
54
|
+
[gh-user-apuratepp]: https://github.com/apuratepp
|
|
55
|
+
[gh-user-czj]: https://github.com/czj
|
|
56
|
+
[gh-user-earlopain]: https://github.com/earlopain
|
|
52
57
|
[gh-user-ginriki]: https://github.com/ginriki
|
|
58
|
+
[gh-user-halostatue]: https://github.com/halostatue
|
|
53
59
|
[gh-user-joshbronson]: https://github.com/joshbronson
|
|
54
60
|
[gh-user-kevinmook]: https://github.com/kevinmook
|
|
55
61
|
[gh-user-mckaz]: https://github.com/mckaz
|
|
56
|
-
[gh-user-
|
|
57
|
-
[gh-user-earlopain]: https://github.com/earlopain
|
|
58
|
-
[gh-user-apuratepp]: https://github.com/apuratepp
|
|
62
|
+
[gh-user-thompson-tomo]: https://github.com/thompson-tomo
|
|
59
63
|
[gh-user-tiendo1011]: https://github.com/tiendo1011
|
data/LICENCE.md
CHANGED
|
@@ -1,47 +1,26 @@
|
|
|
1
1
|
# Licence
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
[Artistic-1.0-Perl][artistic-perl]
|
|
3
|
+
<!-- SPDX-License-Identifier: MIT OR Artistic-1.0-Perl OR GPL-2.0-or-later -->
|
|
5
4
|
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
Algorithm::Diff was dually originally licensed with the Perl Artistic and the
|
|
10
|
-
GNU GPL ("the same terms as Perl itself") and given that the Ruby implementation
|
|
11
|
-
originally hewed pretty closely to the Perl version, I must maintain the
|
|
12
|
-
additional licensing terms.
|
|
5
|
+
Diff::LCS is copyright 2004–2026 Austin Ziegler and contributors, adapted from
|
|
6
|
+
Algorithm::Diff (Perl) by Ned Konz and a Smalltalk diff implementation by
|
|
7
|
+
Mario I. Wolczko.
|
|
13
8
|
|
|
14
|
-
|
|
15
|
-
- Adapted from Algorithm::Diff (Perl) by Ned Konz and a Smalltalk version by
|
|
16
|
-
Mario I. Wolczko.
|
|
9
|
+
This software is available under three disjunctive licences:
|
|
17
10
|
|
|
18
|
-
|
|
11
|
+
- the [MIT license](licences/MIT.txt);
|
|
12
|
+
- the [Perl Artistic license](licences/artistic.txt); or
|
|
13
|
+
- the [GNU GPL version 2](licences/COPYING.txt) (or at your option, a later
|
|
14
|
+
version).
|
|
19
15
|
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
subject to the following conditions:
|
|
16
|
+
Note that my preference for licensing is the MIT license, but Algorithm::Diff
|
|
17
|
+
was dually originally licensed with the Perl Artistic and the GNU GPL ("the
|
|
18
|
+
same terms as Perl itself") and given that the Ruby implementation originally
|
|
19
|
+
hewed pretty closely to the Perl version, I must maintain the additional
|
|
20
|
+
licensing terms.
|
|
26
21
|
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
31
|
-
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
|
|
32
|
-
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
|
|
33
|
-
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
|
|
34
|
-
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
|
|
35
|
-
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
|
36
|
-
|
|
37
|
-
## Perl Artistic License
|
|
38
|
-
|
|
39
|
-
See [licences/artistic.txt](licences/artistic.txt) in the main distribution.
|
|
40
|
-
|
|
41
|
-
## GNU GPL version 2
|
|
42
|
-
|
|
43
|
-
See the file [licences/COPYING.txt](licences/COPYING.txt) in the main
|
|
44
|
-
distribution.
|
|
22
|
+
- SPDX License: [MIT][mit] OR [Artistic-1.0-Perl][artistic-perl] OR
|
|
23
|
+
[GPL-2.0-or-later][gpl2-or-later]
|
|
45
24
|
|
|
46
25
|
## Developer Certificate of Origin
|
|
47
26
|
|
|
@@ -52,7 +31,9 @@ certification of the [Developer Certificate of Origin (Version 1.1)][dco].
|
|
|
52
31
|
Such certification is provided by ensuring that a `Signed-off-by`
|
|
53
32
|
[commit trailer][trailer] is present on every commit:
|
|
54
33
|
|
|
55
|
-
|
|
34
|
+
```text
|
|
35
|
+
Signed-off-by: FirstName LastName <email@example.org>
|
|
36
|
+
```
|
|
56
37
|
|
|
57
38
|
The `Signed-off-by` trailer can be automatically added by git with the `-s` or
|
|
58
39
|
`--signoff` option on `git commit`:
|
data/Manifest.txt
CHANGED
|
@@ -20,14 +20,16 @@ lib/diff/lcs/array.rb
|
|
|
20
20
|
lib/diff/lcs/block.rb
|
|
21
21
|
lib/diff/lcs/callbacks.rb
|
|
22
22
|
lib/diff/lcs/change.rb
|
|
23
|
+
lib/diff/lcs/frozen_value.rb
|
|
23
24
|
lib/diff/lcs/hunk.rb
|
|
24
25
|
lib/diff/lcs/internals.rb
|
|
25
26
|
lib/diff/lcs/ldiff.rb
|
|
26
27
|
lib/diff/lcs/string.rb
|
|
27
28
|
lib/diff/lcs/version.rb
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
29
|
+
licences/COPYING.txt
|
|
30
|
+
licences/MIT.txt
|
|
31
|
+
licences/artistic.txt
|
|
32
|
+
licences/dco.txt
|
|
31
33
|
spec/change_spec.rb
|
|
32
34
|
spec/diff_spec.rb
|
|
33
35
|
spec/hunk_spec.rb
|
|
@@ -67,11 +69,13 @@ test/fixtures/ldiff/output.diff.bin1
|
|
|
67
69
|
test/fixtures/ldiff/output.diff.bin1-c
|
|
68
70
|
test/fixtures/ldiff/output.diff.bin1-e
|
|
69
71
|
test/fixtures/ldiff/output.diff.bin1-f
|
|
72
|
+
test/fixtures/ldiff/output.diff.bin1-q
|
|
70
73
|
test/fixtures/ldiff/output.diff.bin1-u
|
|
71
74
|
test/fixtures/ldiff/output.diff.bin2
|
|
72
75
|
test/fixtures/ldiff/output.diff.bin2-c
|
|
73
76
|
test/fixtures/ldiff/output.diff.bin2-e
|
|
74
77
|
test/fixtures/ldiff/output.diff.bin2-f
|
|
78
|
+
test/fixtures/ldiff/output.diff.bin2-q
|
|
75
79
|
test/fixtures/ldiff/output.diff.bin2-u
|
|
76
80
|
test/fixtures/ldiff/output.diff.chef
|
|
77
81
|
test/fixtures/ldiff/output.diff.chef-c
|
|
@@ -90,6 +94,9 @@ test/fixtures/ldiff/output.diff.four_lines.vs.empty-c
|
|
|
90
94
|
test/fixtures/ldiff/output.diff.four_lines.vs.empty-e
|
|
91
95
|
test/fixtures/ldiff/output.diff.four_lines.vs.empty-f
|
|
92
96
|
test/fixtures/ldiff/output.diff.four_lines.vs.empty-u
|
|
97
|
+
test/fixtures/ldiff/output.diff.hunks
|
|
98
|
+
test/fixtures/ldiff/output.diff.hunks-c
|
|
99
|
+
test/fixtures/ldiff/output.diff.hunks-u
|
|
93
100
|
test/fixtures/ldiff/output.diff.issue95_trailing_context
|
|
94
101
|
test/fixtures/ldiff/output.diff.issue95_trailing_context-c
|
|
95
102
|
test/fixtures/ldiff/output.diff.issue95_trailing_context-e
|
|
@@ -105,13 +112,19 @@ test/fixtures/ldiff/output.diff.missing_new_line2-c
|
|
|
105
112
|
test/fixtures/ldiff/output.diff.missing_new_line2-e
|
|
106
113
|
test/fixtures/ldiff/output.diff.missing_new_line2-f
|
|
107
114
|
test/fixtures/ldiff/output.diff.missing_new_line2-u
|
|
115
|
+
test/fixtures/ldiff/output.diff.same
|
|
116
|
+
test/fixtures/ldiff/output.diff.same-c
|
|
117
|
+
test/fixtures/ldiff/output.diff.same-u
|
|
108
118
|
test/fixtures/new-chef
|
|
109
119
|
test/fixtures/new-chef2
|
|
120
|
+
test/fixtures/new-hunks
|
|
110
121
|
test/fixtures/old-chef
|
|
111
122
|
test/fixtures/old-chef2
|
|
123
|
+
test/fixtures/old-hunks
|
|
112
124
|
test/test_block.rb
|
|
113
125
|
test/test_change.rb
|
|
114
126
|
test/test_diff.rb
|
|
127
|
+
test/test_frozen_value.rb
|
|
115
128
|
test/test_helper.rb
|
|
116
129
|
test/test_hunk.rb
|
|
117
130
|
test/test_issues.rb
|