Disable Irb Autocomplete

Disable irb autocomplete

Try putting this in your ~/.irbrc

IRB.conf[:USE_AUTOCOMPLETE] = false

Disabling irb autocomplete on Heroku

Your application's root directory ends up being the application's user's home directory at Heroku so you could put a .irbrc in your application's root directory. So add your .irbrc with IRB.conf[:USE_AUTOCOMPLETE] = false to your app's root directory so that it looks like this:

$ cd your_app_root_directory
$ ls -1A
.git/
...
.irbrc # <-----------------
...
Gemfile
Gemfile.lock
Procfile
README.md
Rakefile
app/
bin/
config/
config.ru
db/
...

Then, once you push everything up to Heroku, heroku run console will use that .irbrc.

How to disable Pry autocomplete?

Add the following line to your .pryrc config file:

Pry.config.completer = nil

Default value is Pry::InputCompleter

Or you can just launch your console with --noautocomplete option.

Source @ github.com

How to enable auto completion in Ruby's IRB

Just drop require 'irb/completion' in your irbrc.

If that doesn't work try bond, http://tagaholic.me/bond/:

   require 'bond'; require 'bond/completion'

Bond not only improves irb's completion, http://tagaholic.me/2009/07/22/better-irb-completion-with-bond.html, but also offers an easy dsl for making custom autocompletions.

How to turn on the Autocomplete mode in irb mode?

Put in your config something like:

 (defun my-inf-ruby-mode-hook ()
(set (make-local-variable 'ac-auto-start) 2)
(set (make-local-variable 'ac-auto-show-menu) t)
)
(add-hook 'inf-ruby-mode-hook 'my-inf-ruby-mode-hook)

And I think, that you'll also need to setup ac-sources variable in this hook, so it will use ruby dictionaries...

Turn autocomplete off with rails form_tag

As of Rails 4+

Disable autocomplete for an entire form with form_tag:

= form_tag admin_sessions_path, html: { autocomplete: "off" } do

Disable autocomplete for an entire form with form_for:

= form_for @user, html: { autocomplete: "off" } do |f|

Disable autocomplete for a single form element:

= f.text_field :foo, autocomplete: 'off'

Hope this helps!



Related Topics



Leave a reply



Submit