Installing mysql2 gem errors on Apple silicon M1, M2 or M3 Mac running macOS Sonoma.
Make sure mysql-client, openssl and zstd are installed on Mac via Homebrew.
Replace
mysql-clientwith whichever mysql package you are using
import { Controller } from "@hotwired/stimulus"
// Connects to data-controller="form"
export default class extends Controller {
static targets = [ "error" ]
static values = { target: String, action: String }
connect() {
this.target = this.hasTargetValue && document.querySelector(this.targetValue);I was able to get Ruby 2.5.1 building on M1 by following two of the steps in that GH issue...
rbenv/ruby-build#1691 (comment) rbenv/ruby-build#1691 (comment)
I installed readline and openssl with standard brew install.
brew install readline
brew install openssl| # Have you ever wanted lldb to break in a certain place, but you weren't | |
| # sure where to set the breakpoint? Look no further than this script! | |
| # | |
| # This script creates a chunk of executable code that uses the int3 x86 | |
| # instruction. This instruction is defined for use by debuggers, and you can | |
| # read more about it here: https://en.wikipedia.org/wiki/INT_%28x86_instruction%29#INT3 | |
| # | |
| # When that instruction is executed, the debugger will halt and you can do | |
| # what you need! | |
| # |
| // DONT FORGET TO `yarn add esbuild-loader` !!! | |
| // config/webpacker/environment.js | |
| const { environment } = require('@rails/webpacker') | |
| const { ESBuildPlugin } = require('esbuild-loader') | |
| const esBuildUse = [ | |
| { | |
| loader: require.resolve('esbuild-loader'), | |
| // What you want to compile to, in this case, ES7 |
This is all you really need to know in order to make Action Mailbox work in development.
ngrok http 3000 and make note of your subdomain for steps 3 and 8.https://XXX.ngrok.io/rails/action_mailbox/mailgun/inbound_emails/mimeaction_mailbox:
mailgun_api_key: API KEY HERE
| # The following comments fill some of the gaps in Solargraph's understanding of | |
| # Rails apps. Since they're all in YARD, they get mapped in Solargraph but | |
| # ignored at runtime. | |
| # | |
| # You can put this file anywhere in the project, as long as it gets included in | |
| # the workspace maps. It's recommended that you keep it in a standalone file | |
| # instead of pasting it into an existing one. | |
| # | |
| # @!parse | |
| # class ActionController::Base |
initialize: once, when the controller is first instantiatedconnect: anytime the controller is connected to the DOM| # Currently (2017/2018) it's not possible to change the Ruby 'minor' version (eg. 2.3 => 2.4) using the web console | |
| # However, it's possible using the 'awscli' tool. | |
| brew install awscli # pip install awscli | |
| AWS_PROFILE=profile_from_credentials_file AWS_REGION=us-east-2 aws elasticbeanstalk update-environment \ | |
| --platform-arn "arn:aws:elasticbeanstalk:us-east-2::platform/Ruby 3.3 running on 64bit Amazon Linux 2023/4.3.0" \ | |
| --environment-name "myappenv1" --region us-east-2 \ | |
| --version-label "app-1234-210000_120123" | |
| # older awscli using --solution-stack-name |
| <template> | |
| <div></div> | |
| </template> | |
| <script> | |
| import Trix from 'trix'; | |
| export default { | |
| props: ['value'], |