Ticket #4315 enhancement closed fixed

Opened 3 years ago

Last modified 5 months ago

Need convenience command for removing news fragment files

Reported by: jml Owned by: therve
Priority: normal Milestone: regular-releases
Component: release management Keywords:
Cc: thijs Branch: branches/delete-news-fragments-4315
Author: therve Launchpad Bug:

Description (last modified by therve) (diff)

After running build-news as part of the ReleaseProcess and then reviewing and committing the changes, we need to delete the news fragment files (e.g. 2155.bugfix).

Unfortunately, doing this correctly is a bit of a pain. My best guess...

find . -name '*.bugfix' -or -name '*.misc' -or -name '*.feature' -or -name '*.removal' -or -name '*.doc' | xargs svn rm

This should be simpler.

Change History

1

Changed 3 years ago by jml

  • owner glyph deleted
  • component changed from core to release management

2

Changed 3 years ago by jml

  • milestone set to regular-releases

3

Changed 3 years ago by jml

NewsBuilder._headings.keys() is a list of the actual file extensions that ought to be deleted.

4

Changed 3 years ago by therve

  • description modified (diff)

5

Changed 2 years ago by <automation>

6

Changed 18 months ago by thijs

  • cc thijs added

Should this be a new command (clean-news?) or be part of build-news?

7

Changed 18 months ago by exarkun

There doesn't seem to be any reason to make it a separate command. Let's make it part of build-news.

8

Changed 5 months ago by therve

  • owner set to therve

9

Changed 5 months ago by therve

  • branch set to branches/delete-news-fragments-4315
  • branch_author set to therve

(In [36557]) Branching to 'delete-news-fragments-4315'

10

Changed 5 months ago by therve

  • owner therve deleted
  • keywords review added

Alright, let's automate stuff some more! Please review.

11

Changed 5 months ago by tom.prince

12

Changed 5 months ago by tom.prince

  • owner set to therve
  • keywords review removed

1. The docstring should be updated to indicate that build-news must be run from an svn checkout, and that it deletes the news framgments from svn. 1. Before running 'svn rm', the presence of a svn repo should be checked (this code can be shared with buildAllTarballs. I'm not sure what the appropriate behaviour is, if it isn't. I think it is probably to just delete the files. Thus, if it is run in a bzr or git repository, the commit will automatically pick up the removals.

Please resubmit for review.

13

Changed 5 months ago by therve

  • keywords review added
  • owner therve deleted

Thanks for the review. I updated the docstring, and raised an error when it's not a SVN directory. The check is slightly different from the other one so I kept it separated. I don't think we should support other use cases for now.

14

Changed 5 months ago by tom.prince

  • keywords review removed
  • owner set to therve

Looks good. Please commit.

15

Changed 5 months ago by therve

  • status changed from new to closed
  • resolution set to fixed

(In [36726]) Merge delete-news-fragments-4315

Author: therve Reviewer: tom.prince Fixes: #4315

Delete NEWS fragments when building release NEWS files.

Note: See TracTickets for help on using tickets.