Comments (2)
Hi Matti,
Thanks for using tty
and reporting this.
In my experience, you get this behaviour due to git
not tracking the files in newly generated project. Adding exe directory to staged files makes git aware of the folder, meaning, gemspec
can locate the executable and your specs should run fine. In near future, I will improve this experience by stoping to rely on git
for loading files. Trust me I want to provide a very good experience out of the gate. For now I'm creating a roadmap of how tty
v1.0
may look like.
from tty.
For me, even having git add
ed and even committed, I get the same error:
1) `test-app test` command executes `test-app help test` command successfully
Failure/Error: output = `test-app help test`
Errno::ENOENT:
No such file or directory - test-app
# ./spec/integration/test_spec.rb:3:in ``'
# ./spec/integration/test_spec.rb:3:in `block (2 levels) in <top (required)>'
To me, it seems like a PATH issue. If I were to install the gem, it would probably work - but that means it could possibly be testing against a different version of my app, and not the code itself.
However, while looking more into this, I realized that I probably missed a step somewhere. When trying to execute the app with bundle exec test-app
, I got:
[katelyn@h test-app]$ bundler exec test-app
Traceback (most recent call last):
2: from /home/katelyn/.rvm/rubies/ruby-2.6.5/bin/bundler:23:in `<main>'
1: from /home/katelyn/.rvm/rubies/ruby-2.6.5/lib/ruby/site_ruby/2.6.0/rubygems.rb:303:in `activate_bin_path'
/home/katelyn/.rvm/rubies/ruby-2.6.5/lib/ruby/site_ruby/2.6.0/rubygems.rb:284:in `find_spec_for_exe': Could not find 'bundler' (1.17.3) required by your /home/katelyn/code/test-app/Gemfile.lock. (Gem::GemNotFoundException)
To update to the latest version installed on your system, run `bundle update --bundler`.
To install the missing version, run `gem install bundler:1.17.3`
Then:
[katelyn@h test-app]$ bundler exec test-app
bundler: command not found: test-app
Install missing gem executables with `bundle install`
Once I did a bundle-install
, the integration test passed, since test-app
was now found by bundler. As someone who has not used bundler before, I wasn't aware of the pre-requisites so likely that is how I ended up with this. Is there some way to have bundler
look around in the base project dir even if bundler install
has not been ran, or is that an anti-pattern for bundler?
from tty.
Related Issues (20)
- teletype new broken in 0.9.0 HOT 1
- Bundler 2 compatibility HOT 24
- Feature request: add hyperlinks support HOT 2
- Overwrite executable warning when trying to install gem HOT 1
- `teletype new` errors if path contains space HOT 1
- e2e testing doesn't feel good HOT 1
- Warnings with ruby 2.7 HOT 1
- Error with add config HOT 1
- Add vim modeline for indentation HOT 5
- Documentation for template usage HOT 1
- Initial project creation; 'teletype' command throws exception until gemspec is edited HOT 1
- Only require `tty-...` gems that are used in the app HOT 1
- Getting a success indicator in TTY::File.copy_file() HOT 2
- teletype new app -> wrong number of arguments (given 1, expected 0) HOT 6
- TTY is using old version of gem unicorn-display_width HOT 3
- tty not working with Ruby 3.0.0 HOT 1
- tty is not accepting input when generating a new app using Ruby 2.7.2 via asdf HOT 6
- `teletype new` rejects argument HOT 11
- Consider upgrading versions
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from tty.