BewareMyPower commented on code in PR #176:
URL: 
https://github.com/apache/pulsar-client-python/pull/176#discussion_r1430156156


##########
RELEASE.md:
##########
@@ -71,7 +71,7 @@ For patch releases (`X.Y.Z`), you need to reuse the existing 
branch:
 
 ```bash
 git checkout branch-X.Y
-sed -i 's/__version__.*/__version__=X.Y.Z/' pulsar/__about__.py
+sed -i "s/__version__.*/__version__=\"X.Y.Z\"/" pulsar/__about__.py

Review Comment:
   Maybe we can add a workaround for UNIX systems (like macOS) as well. When I 
ran the command on macOS, it failed.
   
   ```bash
   % sed -i "s/__version__.*/__version__=\"3.4.0\"/" pulsar/__about__.py
   sed: 1: "pulsar/__about__.py": extra characters at the end of p command
   ```
   
   While the following command works:
   
   ```bash
   sed -i "" "s/__version__.*/__version__=\"3.4.0\"/" pulsar/__about__.py
   ```
   
   However, it does not work on Linux:
   
   ```
   sed: can't read s/__version__.*/__version__="3.4.0"/: No such file or 
directory
   ```
   
   It's caused by the difference between GNU sed and BSD sed.
   
   To be compatible with both of them, you can use `sed -i.bak` but it will 
generate a `xxx.bak` file.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to