rbenv
Puma
rbenv | Puma | |
---|---|---|
68 | 40 | |
15,864 | 7,605 | |
0.4% | 0.2% | |
6.1 | 8.7 | |
8 days ago | 14 days ago | |
Shell | Ruby | |
MIT License | BSD 3-clause "New" or "Revised" License |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
rbenv
-
Ask HN: Is anybody getting value from AI Agents? How so?
When I was technical blogging on how to learn from open-source code [1], I used it quite frequently to get unstuck and/or to figure out how to tease apart a large question into multiple smaller functions. For example, I had no idea how to break up this long `sed` command [2] into its constituent parts, so I plugged it into ChatGPT and asked it to break down the code for me. I then Googled the different parts to confirm that ChatGPT wasn't leading me astray.
If I had asked StackOverflow the same question, it would have been quickly closed as being not broadly applicable enough (since this `sed` command is quite specific to its use case). After ChatGPT broke the code apart for me, I was able to ask StackOverflow a series of more discrete, more broadly-applicable questions and get a human answer.
TL;DR- I quite like ChatGPT as a search engine when "you don't know what you don't know", and getting unblocked means being pointed in the right direction.
1. https://www.richie.codes/shell
2. https://github.com/rbenv/rbenv/blob/e8b7a27ee67a5751b899215b...
-
Test Driving a Rails API - Part One
Let’s get started. I prefer to manage my Ruby installations on my development machine with chruby paired with ruby-install. Another outstanding set of tools is rbenv with ruby-build. I highly recommend installing Ruby with one of those two sets of tools. Follow the instructions on their project’s READMEs. For this article, I’ll be running Ruby (MRI) v3.3.0.
-
How To Set Up Your Coding Environment
By setting up your environment in isolation, you can prevent yourself from a lot of issues when experimenting with code. It makes your code behave more predictable due to the defined state of the runtime environment you are working with. This article should provide you with enough information to get started, but obviously, there is a lot more power embedded in NVM, Virtual Environment and RBEnv. So make sure to check their documentation.
-
State of Ruby : What version manager to use
There is this good resource that also talk about different ruby version manager from the Rbenv repository. With some links to benchmarks of ASDF and Rbenv.
-
Ruby version
rbenv (my personal favorite)
-
Problems starting msfdb init
One suggestion would be to setup your install based on a development environment using git and a Ruby version manager like rvm or rbenv to allows you to setup a user controlled gemset and execution path.
-
What's the number one reason that you use a Mac over a PC?
rbenv for Ruby
-
Ruby on Rails en Windows con WSL2
git clone https://github.com/rbenv/rbenv.git ~/.rbenv
-
Issues with Unicode in pry running in Debian-11
On MacOS, I haven't had a problem with character encodings in the terminal in ruby for a while, but used to. When I used to, it had to do with how ruby had been installed, in particular that it needed to be compiled linking against an appropriate readline library. Are you trying to use the ruby that came with debian? You might have more luck installing ruby yourself, and using a ruby version manager. rbenv might be the simplest for you.
-
Is there any reason to use Ruby 2.7 over Ruby 3.x?
For my local machine, I use RVM (head). Other options are rbenv and asdf.
Puma
-
Breaking the 300 barrier
As we use Puma as our webserver for our rails application, I quickly went to Puma's config file which typically resides in config/puma.rb. The config was set as
-
Would you consider Rails as stable nowadays ?
They do! It's in the first section of the readme on the repo:
-
Hosting Rails App on AWS
Start with service with systemd
- Recommended way to implement Puma plugin configuration
-
Could not detect rake tasks
# Use the Puma web server [https://github.com/puma/puma] gem "puma", "~> 5.0" # Build JSON APIs with ease [https://github.com/rails/jbuilder] # gem "jbuilder" gem 'rack-cors' gem "devise" gem "jsonapi-serializer" gem 'devise-jwt' gem 'active_model_serializers' gem 'followability' gem 'dotenv-rails', groups: [:development, :test, :production] gem 'sprockets' # Use Redis adapter to run Action Cable in production # gem "redis", "~> 4.0" # Use Kredis to get higher-level data types in Redis [https://github.com/rails/kredis] # gem "kredis" # Use Active Model has_secure_password [https://guides.rubyonrails.org/active_model_basics.html#securepassword] # gem "bcrypt", "~> 3.1.7" # Windows does not include zoneinfo files, so bundle the tzinfo-data gem gem "tzinfo-data", platforms: %i[ mingw mswin x64_mingw jruby ] # Reduces boot times through caching; required in config/boot.rb gem "bootsnap", require: false # Use Active Storage variants [https://guides.rubyonrails.org/active_storage_overview.html#transforming-images] # gem "image_processing", "~> 1.2" # Use Rack CORS for handling Cross-Origin Resource Sharing (CORS), making cross-origin AJAX possible # gem "rack-cors" group :development, :test do # See https://guides.rubyonrails.org/debugging_rails_applications.html#debugging-with-the-debug-gem gem "debug", platforms: %i[ mri mingw x64_mingw ] end group :development do gem "sqlite3", "~> 1.4" # Speed up commands on slow machines / big apps [https://github.com/rails/spring] # gem "spring" end group :production do gem 'pg' end
-
Dusting off my rails knowledge, need some tips / guidance on rails 7 and production
source "https://rubygems.org" git_source(:github) { |repo| "https://github.com/#{repo}.git" } ruby "3.1.0" # Bundle edge Rails instead: gem "rails", github: "rails/rails", branch: "main" gem "rails", "~> 7.0.4", ">= 7.0.4.2" # The original asset pipeline for Rails [https://github.com/rails/sprockets-rails] gem "sprockets-rails" # Use sqlite3 as the database for Active Record gem "sqlite3", "~> 1.4" # Use the Puma web server [https://github.com/puma/puma] gem "puma", "~> 5.0" # Use JavaScript with ESM import maps [https://github.com/rails/importmap-rails] gem "importmap-rails" # Hotwire's SPA-like page accelerator [https://turbo.hotwired.dev] gem "turbo-rails" # Hotwire's modest JavaScript framework [https://stimulus.hotwired.dev] gem "stimulus-rails" # Build JSON APIs with ease [https://github.com/rails/jbuilder] gem "jbuilder" gem "mongoid" gem "mongoid-grid_fs" gem 'bootstrap', '~> 5.2.2' #sourced from https://github.com/twbs/bootstrap-rubygem gem 'rack-cors' # Windows does not include zoneinfo files, so bundle the tzinfo-data gem gem "tzinfo-data", platforms: %i[ mingw mswin x64_mingw jruby ] # Reduces boot times through caching; required in config/boot.rb gem "bootsnap", require: false
-
Write your own Domain Specific Language in Ruby
That doesn't mean one excludes the other. Gems like Puma use the instance_eval method for their configuration file.
- Welcome to Puma 6: Sunflower
-
puma 6.0 released
Anyway I did it: https://github.com/puma/puma/issues/3003 It's quite more complicated: https://github.com/puma/puma/issues/2999 A fix is in progress: https://github.com/puma/puma/pull/3002
What are some alternatives?
asdf - Extendable version manager with support for Ruby, Node.js, Elixir, Erlang & more
Thin - A very fast & simple Ruby web server
RVM - Ruby enVironment Manager (RVM)
falcon - A high-performance web server for Ruby, supporting HTTP/1, HTTP/2 and TLS.
chruby - Changes the current Ruby
Phusion Passenger - A fast and robust web server and application server for Ruby, Python and Node.js
nvm - Node Version Manager - POSIX-compliant bash script to manage multiple active node.js versions
Iodine - iodine - HTTP / WebSockets Server for Ruby with Pub/Sub support
ruby-install - Installs Ruby, JRuby, Rubinius, TruffleRuby or MRuby
Goliath - Goliath is a non-blocking Ruby web server framework
ruby-build - A tool to download, compile, and install Ruby on Unix-like systems.
Unicorn - Unofficial Unicorn Mirror.