Posts

Showing posts from June, 2022

#14. Rails notes command

 raj@linux:~/workspace/test_app$ rails notes -h Usage:   rails notes [options] Options:   -a, [--annotations=one two three]  # Filter by specific annotations, e.g. Foobar TODO Example, raj@linux:~/workspace/test_app$ rails notes -a DEBUG app/controllers/configs_controller.rb:   * [6] This is not exactly working raj@linux:~/workspace/test_app$ rails notes -a DEBUG TEST TODO app/controllers/application_controller.rb:   * [5] [TODO] Check this method for optimization app/controllers/configs_controller.rb:   * [6] [DEBUG] This is not exactly working app/controllers/feedbacks_controller.rb:   * [2] [TEST] Have to write test cases for this method raj@linux:~/workspace/test_app$ rails notes app/controllers/application_controller.rb:   * [5] [TODO] Check this method for optimization

#12. Memcache

Uninstallation/Installation, sudo apt-get remove memcached sudo apt-get remove --auto-remove memcached sudo apt update && sudo apt upgrade sudo apt install memcached  # For the use of mem-cache gem 'dalli' root@test_app:~# memcached -h | head -1 memcached 1.5.22 rails dev:cache root@test_app:~# ls tmp/ cache  data  development_secret.txt  miniprofiler  pids  res  restart.txt  sockets root@test_app:~# rails dev:cache Development mode is now being cached. root@test_app:~# ls tmp/ cache  caching-dev.txt data  development_secret.txt  miniprofiler  pids  res  restart.txt  sockets root@test_app:~# rails dev:cache Development mode is no longer being cached. root@test_app:~# ls tmp/ cache  data  development_secret.txt  miniprofiler  pids  res  restart.txt  sockets touch tmp/restart.txt root@test_app:~# ls tmp/ cache  caching-dev.txt data  development_secret.txt ...

#10. positive? method

 3.0.4 :001 > 0.positive?  => false  3.0.4 :002 > 1.positive?  => true  3.0.4 :003 > -1.positive?  => false