-
-
Notifications
You must be signed in to change notification settings - Fork 33.7k
bpo-32885: Tools/scripts/pathfix.py: Add -n option for no backup~ #5772
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
Conversation
6601b6f to
c04e80d
Compare
Creating backup files with ~ suffix can be undesirable in some environment, such as when building RPM packages. Instead of requiring the user to remove those files manually, option -n was added, that simply disables this feature. -n was selected because 2to3 has the same option with this behavior.
c04e80d to
6a2f23d
Compare
| err('%s: warning: backup failed (%r)\n' % (filename, msg)) | ||
| else: | ||
| try: | ||
| os.remove(filename) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
OK, os.remove() is required for Windows.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Exactly what i thought of when I read the docs for os.move that comes later. Should I explain this in comment?
|
@tiran thanks for swift approval. |
|
@tiran: Please replace |
|
GH-6103 is a backport of this pull request to the 3.7 branch. |
…thonGH-5772) Creating backup files with ~ suffix can be undesirable in some environment, such as when building RPM packages. Instead of requiring the user to remove those files manually, option -n was added, that simply disables this feature. -n was selected because 2to3 has the same option with this behavior. (cherry picked from commit 5affd5c) Co-authored-by: Miro Hrončok <[email protected]>
…thonGH-5772) Creating backup files with ~ suffix can be undesirable in some environment, such as when building RPM packages. Instead of requiring the user to remove those files manually, option -n was added, that simply disables this feature. -n was selected because 2to3 has the same option with this behavior. (cherry picked from commit 5affd5c) Co-authored-by: Miro Hrončok <[email protected]>
|
GH-6104 is a backport of this pull request to the 3.6 branch. |
…p~ (GH-5772) (#6104) Creating backup files with ~ suffix can be undesirable in some environment, such as when building RPM packages. Instead of requiring the user to remove those files manually, option -n was added, that simply disables this feature. -n was selected because 2to3 has the same option with this behavior. (cherry picked from commit 5affd5c) Co-authored-by: Miro Hrončok <[email protected]>
…p~ (GH-5772) (#6103) Creating backup files with ~ suffix can be undesirable in some environment, such as when building RPM packages. Instead of requiring the user to remove those files manually, option -n was added, that simply disables this feature. -n was selected because 2to3 has the same option with this behavior. (cherry picked from commit 5affd5c) Co-authored-by: Miro Hrončok <[email protected]>
…thon#5772) Creating backup files with ~ suffix can be undesirable in some environment, such as when building RPM packages. Instead of requiring the user to remove those files manually, option -n was added, that simply disables this feature. -n was selected because 2to3 has the same option with this behavior.
Creating backup files with
~suffix can be undesirable in some environment, such as when building RPM packages. Instead of requiring the user to remove those files manually, option-nwas added, that simply disables this feature.-nwas selected because 2to3 has the same option with this behavior.https://bugs.python.org/issue32885