Skip to content

Commit a59492a

Browse files
committed
Clean up whitespace.
Hate that trailing stuff.
1 parent 9ca7159 commit a59492a

File tree

10 files changed

+35
-35
lines changed

10 files changed

+35
-35
lines changed

examples/demo/app.rb

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,12 +15,12 @@ class App < Sinatra::Base
1515
out << '<input type="submit" value="Create New Job"/>'
1616
out << '&nbsp;&nbsp;<a href="/resque/">View Resque</a>'
1717
out << '</form>'
18-
18+
1919
out << "<form action='/failing' method='POST''>"
2020
out << '<input type="submit" value="Create Failing New Job"/>'
2121
out << '&nbsp;&nbsp;<a href="/resque/">View Resque</a>'
2222
out << '</form>'
23-
23+
2424
out << "</body></html>"
2525
out
2626
end
@@ -29,8 +29,8 @@ class App < Sinatra::Base
2929
Resque.enqueue(Job, params)
3030
redirect "/"
3131
end
32-
33-
post '/failing' do
32+
33+
post '/failing' do
3434
Resque.enqueue(FailingJob, params)
3535
redirect "/"
3636
end

examples/demo/job.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ def self.perform(params)
99
puts "Processed a job!"
1010
end
1111
end
12-
12+
1313
module FailingJob
1414
@queue = :failing
1515

lib/resque/failure.rb

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -62,23 +62,23 @@ def self.clear
6262
def self.requeue(index)
6363
backend.requeue(index)
6464
end
65-
65+
6666
def self.requeue_to(index, queue_name)
6767
backend.requeue(index, queue_name)
6868
end
6969

7070
def self.remove(index)
7171
backend.remove(index)
7272
end
73-
73+
7474
# Requeues all failed jobs in a specific queue.
7575
# Queue name should be a string.
7676
def self.requeue_queue(queue)
7777
i=0
7878
while job = Resque::Failure.all(i)
7979
if job['queue'] == queue
8080
Resque::Failure.requeue(i)
81-
end
81+
end
8282
i+=1
8383
end
8484
end
@@ -92,7 +92,7 @@ def self.remove_queue(queue)
9292
# This will remove the failure from the array so do not increment the index.
9393
Resque::Failure.remove(i)
9494
else
95-
i+=1
95+
i+=1
9696
end
9797
end
9898
end

lib/resque/failure/base.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,11 +44,11 @@ def self.all(start = 0, count = 1)
4444
# A URL where someone can go to view failures.
4545
def self.url
4646
end
47-
47+
4848
# Clear all failure objects
4949
def self.clear
5050
end
51-
51+
5252
def self.requeue(index)
5353
end
5454

lib/resque/failure/redis.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ def self.requeue(index)
3737
Resque.redis.lset(:failed, index, Resque.encode(item))
3838
Job.create(item['queue'], item['payload']['class'], *item['payload']['args'])
3939
end
40-
40+
4141
def self.requeue_to(index, queue_name)
4242
item = all(index)
4343
item['retried_at'] = Time.now.strftime("%Y/%m/%d %H:%M:%S")

lib/resque/server/public/reset.css

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -6,39 +6,39 @@ small, strike, strong, sub, sup, tt, var,
66
dl, dt, dd, ul, li,
77
form, label, legend,
88
table, caption, tbody, tfoot, thead, tr, th, td {
9-
margin: 0;
10-
padding: 0;
11-
border: 0;
12-
outline: 0;
13-
font-weight: inherit;
14-
font-style: normal;
15-
font-size: 100%;
16-
font-family: inherit;
9+
margin: 0;
10+
padding: 0;
11+
border: 0;
12+
outline: 0;
13+
font-weight: inherit;
14+
font-style: normal;
15+
font-size: 100%;
16+
font-family: inherit;
1717
}
1818

1919
body {
20-
line-height: 1;
20+
line-height: 1;
2121
}
2222

2323
ul {
24-
list-style: none;
24+
list-style: none;
2525
}
2626

2727
table {
28-
border-collapse: collapse;
29-
border-spacing: 0;
28+
border-collapse: collapse;
29+
border-spacing: 0;
3030
}
3131

3232
caption, th, td {
33-
text-align: left;
34-
font-weight: normal;
33+
text-align: left;
34+
font-weight: normal;
3535
}
3636

3737
blockquote:before, blockquote:after,
3838
q:before, q:after {
39-
content: "";
39+
content: "";
4040
}
4141

4242
blockquote, q {
43-
quotes: "" "";
43+
quotes: "" "";
4444
}

lib/resque/server/test_helper.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ class MiniTest::Unit::TestCase
77
include Rack::Test::Methods
88
def app
99
Resque::Server.new
10-
end
10+
end
1111

1212
def self.should_respond_with_success
1313
it "should respond with success" do

lib/resque/worker.rb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -557,7 +557,7 @@ def worker_pids
557557
if RUBY_PLATFORM =~ /solaris/
558558
solaris_worker_pids
559559
elsif RUBY_PLATFORM =~ /mingw32/
560-
windows_worker_pids
560+
windows_worker_pids
561561
else
562562
linux_worker_pids
563563
end
@@ -591,14 +591,14 @@ def get_worker_pids(command)
591591
active_worker_pids = []
592592
output = %x[#{command}] # output format of ps must be ^<PID> <COMMAND WITH ARGS>
593593
raise 'System call for ps command failed. Please make sure that you have a compatible ps command in the path!' unless $?.success?
594-
output.split($/).each{|line|
594+
output.split($/).each{|line|
595595
next unless line =~ /resque/i
596596
next if line =~ /resque-web/
597597
active_worker_pids.push line.split(' ')[0]
598598
}
599599
active_worker_pids
600600
end
601-
601+
602602
# Given a string, sets the procline ($0) and logs.
603603
# Procline is always in the format of:
604604
# resque-VERSION: STRING

test/resque-web_test.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
require 'test_helper'
22
require 'resque/server/test_helper'
3-
3+
44
# Root path test
55
describe "on GET to /" do
66
before { get "/" }
@@ -33,7 +33,7 @@
3333
should_respond_with_success
3434
end
3535

36-
# Stats
36+
# Stats
3737
describe "on GET to /stats/resque" do
3838
before { get "/stats/resque" }
3939

test/worker_test.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
end
2828

2929
it "unavailable job definition reports exception and message" do
30-
Resque::Job.create(:jobs, 'NoJobDefinition')
30+
Resque::Job.create(:jobs, 'NoJobDefinition')
3131
@worker.work(0)
3232
assert_equal 1, Resque::Failure.count, 'failure not reported'
3333
assert_equal('NameError', Resque::Failure.all['exception'])

0 commit comments

Comments
 (0)