Project

rstrip

0.01
No commit activity in last 3 years
No release in over 3 years
A ruby executable that removes the trailing white space in the current project directory. It also remove the last empty line if there is one
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

~> 0.5.3
~> 2.13.0

Runtime

>= 0
 Project Readme

Introduction

rstrip provides a ruby executable that removes the trailing white space in the current project directory.

It also remove empty lines at the end of a file.

It's configurable on the file types it will operate on.

Usage

  • Install the gem: gem install rstrip
  • In your project folder run rstrip config generate, or run rstrip config generate --global true to generate the config file in your home directory
  • Modify the list of file extensions in the .rstrip config file
  • In your project folder run rstrip process
  • Examine the changes and commit the code

Alternatives

There are a lot of ways to do the similar thing:

I used the textmate marco before. The problem with textmate bundle or marco is they only modify the file if you edit and save it, which makes the commits harder to read as you will remove white spaces gradually. rstrip gets it done all in once in the folder level. Then you can use the bundle or marco with a fresh start.

rstrip also tries to make it as easy as possible so you don't need to remember the cryptic bash or perl commands.