You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Perhaps more of a feature suggestion than a problem :) I noticed that when making a new app with teletype, it adds all of the 'tty' gems as dependencies, even though (by default) none of them are used or required:
This seems inefficient; if I install this gem straight out of the box - no commands added, etc - I'd get 20 other gems along with it, even though none of them are used (seemingly).
Steps to reproduce the problem
teletype new test-app
grep 'dependency' test-app/test-app.gemspec
Expected Suggested behaviour
My initial thoughts were:
a) use the 'teletype' command to add a new component. for example, teletype require prompt (???)
b) when running rake build, scrape any requires that reference a tty gem
Option "b" sounds more automated (yay!) but hacky (boo!). Option "a" feels clunky (i.e. why would i need to run teletype instead of just adding a require 'tty/prompt' line..?)... so I'm not sure either suggestion is the best. Opening this more for discussion than anything!
Describe your environment
OS version: Arch Linux/kernel 5.8.9
Ruby version: 2.6.5
TTY version: 0.10.0
The text was updated successfully, but these errors were encountered:
💯 agree, teleteype needs to only add what's needed. There is a short and long term plan for handling this.
The short term plan is to inject tty dependencies as comments in the gemspec file for user to pick and choose. This is currently implemented in the master branch. If you could test against master branch that would be better as the v0.10.0 is pretty outdated and in dire need of new release as evidenced in Bundler issue.
The long term plan is to use tty-prompt to ask the user multiple choice question about which dependencies they would like to use and add these to the generated gemspec and as requirements in the command.rb file or some other place. However, this would need to wait for when I replace Bundler with custom gemspec generator. I want to as quickly as possible get to release v0.11.0 that has all the updated components(only 2 still left to do).
This comment I made in the referenced issue above explains the 3 stage plan of where I think I want to go with this project. So in the first stage, all tty components would be injected as commented out dependencies. It's kind of similar to how rails setups some of its dependencies.
Please let me know if you like this approach as a first step?
Describe the problem
Perhaps more of a feature suggestion than a problem :) I noticed that when making a new app with
teletype
, it adds all of the 'tty' gems as dependencies, even though (by default) none of them are used orrequire
d:This seems inefficient; if I install this gem straight out of the box - no commands added, etc - I'd get 20 other gems along with it, even though none of them are used (seemingly).
Steps to reproduce the problem
ExpectedSuggested behaviourMy initial thoughts were:
a) use the 'teletype' command to add a new component. for example,
teletype require prompt
(???)b) when running
rake build
, scrape anyrequire
s that reference a tty gemOption "b" sounds more automated (yay!) but hacky (boo!). Option "a" feels clunky (i.e. why would i need to run
teletype
instead of just adding arequire 'tty/prompt'
line..?)... so I'm not sure either suggestion is the best. Opening this more for discussion than anything!Describe your environment
The text was updated successfully, but these errors were encountered: