On Jan 26, 8:19=A0am, Tony Meier <ton... / yahoo.com> wrote:
> I've tried adding a launcher script into /bin and adding it to the
> gemspec like this
>
> spec =3D Gem::Specification.new do |s|
> =A0 s.name =3D 'appname'
> =A0 s.version =3D '0.0.3'
> =A0 s.summary =3D 'desc'
> =A0 s.description =3D %{desc}
> =A0 s.test_files =3D Dir['test/*.rb']
> =A0 s.bindir =3D 'bin'

You also need to specify the executable(s) inside the bindir that you
want installed:

s.executables << 'my_app_name'

You don't even need it to have a .rb extension if you have a shebang
line at the top.
(Even works on Windows.)
#!/usr/bin/env ruby -KU