Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
O
OHR Support
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
97
Issues
97
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Wiki
Wiki
image/svg+xml
Discourse
Discourse
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Projects
OHR Support
Commits
05a4c461
Commit
05a4c461
authored
May 29, 2011
by
Eric Davis
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[
#262
] Add a rake task to convert line endings to UNIX
parent
bc249871
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
0 deletions
+14
-0
code.rake
lib/tasks/code.rake
+14
-0
No files found.
lib/tasks/code.rake
0 → 100644
View file @
05a4c461
namespace
:code
do
desc
"Fix line endings of all source files"
task
:fix_line_endings
do
unless
`which fromdos`
.
present?
raise
"fromdos command not found"
end
Dir
[
'**/**{.rb,.html.erb,.rhtml,.rjs,.rsb,.plain.erb,.rxml,.yml,.rake,.eml}'
].
each
do
|
file_name
|
next
if
file_name
.
include?
(
"vendor"
)
system
(
"fromdos
#{
file_name
}
"
)
end
end
end
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment