Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

automatically ignore template files #633

Merged
merged 11 commits into from
Jul 31, 2024
Merged

automatically ignore template files #633

merged 11 commits into from
Jul 31, 2024

Conversation

aviramha
Copy link
Contributor

Automatically ignore template files

Closes #632

@aviramha
Copy link
Contributor Author

Not sure if I should create a changelog that is fixed or added

Copy link
Member

@adiroiban adiroiban left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the quick update.
This is a good start.

We can consider it a bugfix.

The tests needs to pass in order to merge this.

Thanks again

src/towncrier/test/test_build.py Show resolved Hide resolved
src/towncrier/test/test_build.py Outdated Show resolved Hide resolved
src/towncrier/_builder.py Show resolved Hide resolved
NEWS.rst Outdated Show resolved Hide resolved
src/towncrier/test/test_build.py Show resolved Hide resolved
Co-authored-by: Adi Roiban <adiroiban@gmail.com>
@adiroiban
Copy link
Member

The documentation also needs to be updated.

Some filenames such as .gitignore and README are automatically ignored. However, if a custom template is stored in the news fragment directory, you should add it to this list.

Maybe something like this

-Some filenames such as .gitignore and README are automatically ignored. However, if a custom template is stored in the news fragment directory, you should add it to this list.
+Some filenames such as .gitignore, README.rst. README.md, and the template file, are automatically ignored.

aviramha and others added 2 commits July 31, 2024 15:13
Co-authored-by: Adi Roiban <adiroiban@gmail.com>
Copy link
Member

@adiroiban adiroiban left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It looks good. Many thanks for the update.

@adiroiban
Copy link
Member

Sorry for the mess. I will try to get this this merged and then look at doing a new release.

@adiroiban adiroiban merged commit 67c9fd2 into twisted:trunk Jul 31, 2024
16 checks passed
# Template can be a tuple of (package_name, resource_name).
#
# See https://github.com/twisted/towncrier/issues/634
ignored_files.add(config.template)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is not ok.

We should extract the filename from the filepath.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Regression/breakage on 24.7.0 - check for invalid files
2 participants