rascut 0.1.2 → 0.1.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,4 +1,10 @@
1
+ == 0.1.3 / 2007-10-09
2
+
3
+ * Support new flex3 SDK beta version, maybe.
4
+ * Gem package generater change hoe to cutagem.
5
+
1
6
  == 0.1.2 / 2007-09-27
7
+
2
8
  * Append commandline --version option
3
9
  * Fix file observer for win32(winXP). thx ameema
4
10
  * Fix httpd compileoption bug
data/Rakefile CHANGED
@@ -1,26 +1,137 @@
1
- # -*- ruby -*-
2
-
3
1
  require 'rubygems'
4
- require 'hoe'
5
- $LOAD_PATH << './lib'
6
- require './lib/rascut.rb'
7
- require 'tmpdir'
8
-
9
- ENV['HOME'] ||= Dir.tmpdir # for Hoe's bug.
10
-
11
- Hoe.new('rascut', Rascut::VERSION) do |p|
12
- p.rubyforge_name = 'hotchpotch'
13
- p.author = 'yuichi tateno'
14
- p.email = 'hotchpotch@nononospam@gmail.com'
15
- p.summary = 'Ruby ActionSCript UTility'
16
- p.description = p.paragraphs_of('README.txt', 2..5).join("\n\n")
17
- p.url = p.paragraphs_of('README.txt', 0).first.split(/\n/)[1..-1]
18
- p.changes = p.paragraphs_of('History.txt', 0..1).join("\n\n")
19
-
20
- p.extra_deps << ['mongrel']
21
- p.extra_deps << ['rake']
22
- p.extra_deps << ['hoe']
23
- p.extra_deps << ['rack']
2
+ require 'rake'
3
+ require 'rake/clean'
4
+ require 'rake/testtask'
5
+ require 'rake/packagetask'
6
+ require 'rake/gempackagetask'
7
+ require 'rake/rdoctask'
8
+ require 'rake/contrib/rubyforgepublisher'
9
+ require 'fileutils'
10
+ include FileUtils
11
+
12
+ require 'lib/rascut'
13
+
14
+ AUTHOR = "Yuichi Tateno"
15
+ EMAIL = "hotchpotch@nospam@gmail.com"
16
+ DESCRIPTION = "Ruby ActionSCript UTility"
17
+ RUBYFORGE_PROJECT = "hotchpotch"
18
+ HOMEPATH = "http://#{RUBYFORGE_PROJECT}.rubyforge.org/rascut/"
19
+ BIN_FILES = %w(rascut)
20
+ VERS = Rascut::VERSION
21
+
22
+
23
+ NAME = "rascut"
24
+ REV = File.read(".svn/entries")[/committed-rev="(d+)"/, 1] rescue nil
25
+ CLEAN.include ['**/.*.sw?', '*.gem', '.config']
26
+ RDOC_OPTS = ['--title', "#{NAME} documentation",
27
+ "--charset", "utf-8",
28
+ "--opname", "index.html",
29
+ "--line-numbers",
30
+ "--main", "README",
31
+ "--inline-source",
32
+ ]
33
+
34
+ desc "Packages up #{NAME} gem."
35
+ task :default => [:test]
36
+ task :package => [:clean]
37
+
38
+ Rake::TestTask.new("test") { |t|
39
+ t.libs << "test"
40
+ t.pattern = "test/**/test_*.rb"
41
+ t.verbose = true
42
+ }
43
+
44
+ spec = Gem::Specification.new do |s|
45
+ s.name = NAME
46
+ s.version = VERS
47
+ s.platform = Gem::Platform::RUBY
48
+ s.has_rdoc = true
49
+ s.extra_rdoc_files = ["README", "ChangeLog"]
50
+ s.rdoc_options += RDOC_OPTS + ['--exclude', '^(examples|extras)/']
51
+ s.summary = DESCRIPTION
52
+ s.description = DESCRIPTION
53
+ s.author = AUTHOR
54
+ s.email = EMAIL
55
+ s.homepage = HOMEPATH
56
+ s.executables = BIN_FILES
57
+ s.rubyforge_project = RUBYFORGE_PROJECT
58
+ s.bindir = "bin"
59
+ s.require_path = "lib"
60
+ s.autorequire = ""
61
+ s.test_files = Dir["test/test_*.rb"]
62
+
63
+ s.add_dependency('rake')
64
+ s.add_dependency('mongrel')
65
+ s.add_dependency('rack')
66
+ s.required_ruby_version = '>= 1.8.2'
67
+
68
+ s.files = %w(README ChangeLog Rakefile) +
69
+ Dir.glob("{bin,doc,test,lib,templates,generator,extras,website,script}/**/*") +
70
+ Dir.glob("ext/**/*.{h,c,rb}") +
71
+ Dir.glob("examples/**/*.rb") +
72
+ Dir.glob("tools/*.rb") +
73
+ Dir.glob("vendor/*") +
74
+ Dir.glob("vendor/*/**")
75
+
76
+ s.extensions = FileList["ext/**/extconf.rb"].to_a
24
77
  end
25
78
 
26
- # vim: syntax=Ruby
79
+ Rake::GemPackageTask.new(spec) do |p|
80
+ p.need_tar = true
81
+ p.gem_spec = spec
82
+ end
83
+
84
+ task :install do
85
+ name = "#{NAME}-#{VERS}.gem"
86
+ sh %{rake package}
87
+ sh %{sudo gem install pkg/#{name}}
88
+ end
89
+
90
+ task :uninstall => [:clean] do
91
+ sh %{sudo gem uninstall #{NAME}}
92
+ end
93
+
94
+
95
+ Rake::RDocTask.new do |rdoc|
96
+ rdoc.rdoc_dir = 'html'
97
+ rdoc.options += RDOC_OPTS
98
+ rdoc.template = "resh"
99
+ #rdoc.template = "#{ENV['template']}.rb" if ENV['template']
100
+ if ENV['DOC_FILES']
101
+ rdoc.rdoc_files.include(ENV['DOC_FILES'].split(/,\s*/))
102
+ else
103
+ rdoc.rdoc_files.include('README', 'ChangeLog')
104
+ rdoc.rdoc_files.include('lib/**/*.rb')
105
+ rdoc.rdoc_files.include('ext/**/*.c')
106
+ end
107
+ end
108
+
109
+ desc "Publish to RubyForge"
110
+ task :rubyforge => [:rdoc, :package] do
111
+ Rake::RubyForgePublisher.new(RUBYFORGE_PROJECT, 'secondlife').upload
112
+ end
113
+
114
+ desc 'Package and upload the release to rubyforge.'
115
+ task :release => [:clean, :package] do |t|
116
+ v = ENV["VERSION"] or abort "Must supply VERSION=x.y.z"
117
+ abort "Versions don't match #{v} vs #{VERS}" unless v == VERS
118
+ pkg = "pkg/#{NAME}-#{VERS}"
119
+
120
+ require 'rubyforge'
121
+ rf = RubyForge.new
122
+ puts "Logging in"
123
+ rf.login
124
+
125
+ c = rf.userconfig
126
+ # c["release_notes"] = description if description
127
+ # c["release_changes"] = changes if changes
128
+ c["preformatted"] = true
129
+
130
+ files = [
131
+ "#{pkg}.tgz",
132
+ "#{pkg}.gem"
133
+ ].compact
134
+
135
+ puts "Releasing #{NAME} v. #{VERS}"
136
+ rf.add_release RUBYFORGE_PROJECT, NAME, VERS, *files
137
+ end
@@ -35,15 +35,15 @@ module Rascut
35
35
  def process_sync_exec(str, result_get = true)
36
36
  res = nil
37
37
  @mutex.synchronize do
38
- @process.puts str
39
- res = read_result(@process) if result_get
38
+ process.puts str
39
+ res = read_result(process) if result_get
40
40
  end
41
41
  res
42
42
  end
43
43
 
44
44
  def close
45
- if @process
46
- @process.close
45
+ if process
46
+ process.close
47
47
  call_hook :close
48
48
  end
49
49
  end
@@ -58,13 +58,22 @@ module Rascut
58
58
  cmd
59
59
  end
60
60
 
61
+ def process
62
+ unless @process
63
+ orig_lang = ENV['LANG']
64
+ ENV['LANG'] = 'C' # for flex3 sdk beta locale
65
+ @process = IO.popen(@config[:fcsh_cmd] + ' 2>&1', 'r+') unless @process
66
+ ENV['LANG'] = orig_lang
67
+ end
68
+ @process
69
+ end
70
+
61
71
  def compile
62
72
  return false if @compile_mutex.locked?
63
73
 
64
74
  @compile_mutex.synchronize do
65
75
  logger.info "Compile Start"
66
76
  out = nil
67
- @process = IO.popen(@config[:fcsh_cmd] + ' 2>&1', 'r+') unless @process
68
77
  if @compile_id
69
78
  out = process_sync_exec "compile #{@compile_id}"
70
79
  else
data/lib/rascut.rb CHANGED
@@ -1,6 +1,6 @@
1
1
 
2
2
  module Rascut
3
- VERSION = '0.1.2'
3
+ VERSION = '0.1.3'
4
4
  end
5
5
 
6
6
  require 'rascut/logger'
metadata CHANGED
@@ -3,60 +3,72 @@ rubygems_version: 0.9.1
3
3
  specification_version: 1
4
4
  name: rascut
5
5
  version: !ruby/object:Gem::Version
6
- version: 0.1.2
7
- date: 2007-09-29 00:00:00 +09:00
6
+ version: 0.1.3
7
+ date: 2007-10-09 00:00:00 +09:00
8
8
  summary: Ruby ActionSCript UTility
9
9
  require_paths:
10
10
  - lib
11
- email: hotchpotch@nononospam@gmail.com
12
- homepage: " by Yuichi Tateno"
11
+ email: hotchpotch@nospam@gmail.com
12
+ homepage: http://hotchpotch.rubyforge.org/rascut/
13
13
  rubyforge_project: hotchpotch
14
- description: "== FEATURES/PROBLEMS: == SYNOPSIS: * 1. flex2sdk and fcwrap setting. * 2. $ rascut -s MyScript.as * 3. Browser access http://localhost:3001/ == REQUIREMENTS:"
15
- autorequire:
14
+ description: Ruby ActionSCript UTility
15
+ autorequire: ""
16
16
  default_executable:
17
17
  bindir: bin
18
18
  has_rdoc: true
19
19
  required_ruby_version: !ruby/object:Gem::Version::Requirement
20
20
  requirements:
21
- - - ">"
21
+ - - ">="
22
22
  - !ruby/object:Gem::Version
23
- version: 0.0.0
23
+ version: 1.8.2
24
24
  version:
25
25
  platform: ruby
26
26
  signing_key:
27
27
  cert_chain:
28
28
  post_install_message:
29
29
  authors:
30
- - yuichi tateno
30
+ - Yuichi Tateno
31
31
  files:
32
- - History.txt
33
- - Manifest.txt
34
- - README.txt
32
+ - README
33
+ - ChangeLog
35
34
  - Rakefile
36
35
  - bin/rascut
36
+ - test/test_rascut.rb
37
+ - test/test_file_observer.rb
37
38
  - lib/rascut.rb
38
- - lib/rascut/command.rb
39
- - lib/rascut/config.rb
40
- - lib/rascut/fcsh_wrapper.rb
39
+ - lib/rascut
41
40
  - lib/rascut/file_observer.rb
41
+ - lib/rascut/config.rb
42
42
  - lib/rascut/httpd.rb
43
43
  - lib/rascut/logger.rb
44
- - lib/rascut/plugin/base.rb
44
+ - lib/rascut/plugin
45
45
  - lib/rascut/plugin/write_fcsh_error_output.rb
46
- - vendor/ruby/expect.rb
46
+ - lib/rascut/plugin/base.rb
47
+ - lib/rascut/command.rb
48
+ - lib/rascut/fcsh_wrapper.rb
49
+ - vendor/js
50
+ - vendor/ruby
47
51
  - vendor/js/swfobject.js
48
- - test/test_rascut.rb
49
- - test/test_file_observer.rb
52
+ - vendor/ruby/expect.rb
50
53
  test_files:
51
54
  - test/test_rascut.rb
52
55
  - test/test_file_observer.rb
53
56
  rdoc_options:
57
+ - --title
58
+ - rascut documentation
59
+ - --charset
60
+ - utf-8
61
+ - --opname
62
+ - index.html
63
+ - --line-numbers
54
64
  - --main
55
- - README.txt
65
+ - README
66
+ - --inline-source
67
+ - --exclude
68
+ - ^(examples|extras)/
56
69
  extra_rdoc_files:
57
- - History.txt
58
- - Manifest.txt
59
- - README.txt
70
+ - README
71
+ - ChangeLog
60
72
  executables:
61
73
  - rascut
62
74
  extensions: []
@@ -64,15 +76,6 @@ extensions: []
64
76
  requirements: []
65
77
 
66
78
  dependencies:
67
- - !ruby/object:Gem::Dependency
68
- name: mongrel
69
- version_requirement:
70
- version_requirements: !ruby/object:Gem::Version::Requirement
71
- requirements:
72
- - - ">"
73
- - !ruby/object:Gem::Version
74
- version: 0.0.0
75
- version:
76
79
  - !ruby/object:Gem::Dependency
77
80
  name: rake
78
81
  version_requirement:
@@ -83,7 +86,7 @@ dependencies:
83
86
  version: 0.0.0
84
87
  version:
85
88
  - !ruby/object:Gem::Dependency
86
- name: hoe
89
+ name: mongrel
87
90
  version_requirement:
88
91
  version_requirements: !ruby/object:Gem::Version::Requirement
89
92
  requirements:
@@ -100,12 +103,3 @@ dependencies:
100
103
  - !ruby/object:Gem::Version
101
104
  version: 0.0.0
102
105
  version:
103
- - !ruby/object:Gem::Dependency
104
- name: hoe
105
- version_requirement:
106
- version_requirements: !ruby/object:Gem::Version::Requirement
107
- requirements:
108
- - - ">="
109
- - !ruby/object:Gem::Version
110
- version: 1.3.0
111
- version:
data/Manifest.txt DELETED
@@ -1,18 +0,0 @@
1
- History.txt
2
- Manifest.txt
3
- README.txt
4
- Rakefile
5
- bin/rascut
6
- lib/rascut.rb
7
- lib/rascut/command.rb
8
- lib/rascut/config.rb
9
- lib/rascut/fcsh_wrapper.rb
10
- lib/rascut/file_observer.rb
11
- lib/rascut/httpd.rb
12
- lib/rascut/logger.rb
13
- lib/rascut/plugin/base.rb
14
- lib/rascut/plugin/write_fcsh_error_output.rb
15
- vendor/ruby/expect.rb
16
- vendor/js/swfobject.js
17
- test/test_rascut.rb
18
- test/test_file_observer.rb
File without changes