Skip to content

Commit 1fe1689

Browse files
Organize codegen-related bits under codegen/*
1 parent 9379879 commit 1fe1689

8 files changed

+8
-32
lines changed

.gitmodules

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
1-
[submodule "vendor/rabbitmq-codegen"]
2-
path = vendor/rabbitmq-codegen
1+
[submodule "codegen/rabbitmq-codegen"]
2+
path = codegen/rabbitmq-codegen
33
url = git://github.com/rabbitmq/rabbitmq-codegen.git
File renamed without changes.
File renamed without changes.

codegen.py renamed to codegen/codegen.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77
import os, sys, re
88

9-
sys.path.append(os.path.join("vendor", "rabbitmq-codegen"))
9+
sys.path.append(os.path.join("codegen", "rabbitmq-codegen"))
1010

1111
from amqp_codegen import *
1212
try:
@@ -61,7 +61,7 @@ def new_init(self, arg):
6161

6262
# method.accepted_by("server")
6363
# method.accepted_by("client", "server")
64-
accepted_by_update = json.loads(file("amqp_0.9.1_changes.json").read())
64+
accepted_by_update = json.loads(file("codegen/amqp_0.9.1_changes.json").read())
6565

6666
def accepted_by(self, *receivers):
6767
def get_accepted_by(self):
File renamed without changes.

codegen/rabbitmq-codegen

Submodule rabbitmq-codegen added at 7597914

generate.rb

+3-3
Original file line numberDiff line numberDiff line change
@@ -5,14 +5,14 @@ def sh(*args)
55
system(*args)
66
end
77

8-
spec = "vendor/rabbitmq-codegen/amqp-rabbitmq-0.9.1.json"
8+
spec = "codegen/rabbitmq-codegen/amqp-rabbitmq-0.9.1.json"
99
unless File.exist?(spec)
1010
sh "git submodule update --init"
1111
end
1212

1313
path = "lib/amq/protocol/client.rb"
14-
sh "./codegen.py client #{spec} #{path}"
14+
puts "Running ./codegen/codegen.py client #{spec} #{path}"
15+
sh "./codegen/codegen.py client #{spec} #{path}"
1516
if File.file?(path)
16-
sh "./post-processing.rb #{path}"
1717
sh "ruby -c #{path}"
1818
end

post-processing.rb

-25
This file was deleted.

0 commit comments

Comments
 (0)