Skip to content

Conversation

@schwehr
Copy link
Contributor

@schwehr schwehr commented Aug 28, 2024

Before:

file *.py
setup.py:          Python script, ASCII text executable
shapefile.py:      Python script, ASCII text executable, with CRLF line terminators
test_shapefile.py: Python script, ASCII text executable

Do the strip:

perl -pi -e 's/\s+\n/\n/g' *.py

After:

file *.py
setup.py:          Python script, ASCII text executable
shapefile.py:      Python script, ASCII text executable
test_shapefile.py: Python script, ASCII text executable

Move shapefile.py back to dos formatting:

unix2dos shapefile.py

Before:

```
file *.py
setup.py:          Python script, ASCII text executable
shapefile.py:      Python script, ASCII text executable, with CRLF line terminators
test_shapefile.py: Python script, ASCII text executable
```

Do the strip:

```
perl -pi -e 's/\s+\n/\n/g' *.py
```

After:

```
file *.py
setup.py:          Python script, ASCII text executable
shapefile.py:      Python script, ASCII text executable
test_shapefile.py: Python script, ASCII text executable
```

Move `shapefile.py` back to dos formatting:

```
unix2dos shapefile.py
```
@JamesParrott
Copy link
Collaborator

Looks fine. Many thanks Kurt.

@JamesParrott JamesParrott merged commit 5c3a941 into GeospatialPython:master Sep 7, 2024
@schwehr schwehr deleted the rm-trailing-spaces-in-py branch September 7, 2024 15:09
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.

2 participants