Subject: bug#72099: 31.0.50; ruby-mode indentation of inline array and hash arguments

From: Aaron Jensen <[email-masked]>
Date: Sat, 13 Jul 2024 15:59:12 -0400

I'd like ruby-mode to indent like the following:

some_object.some_method([
  some_item
])

Currently, it indents like this:

some_object.some_method([
                          some_item
                        ])

I don't recall if I have reported this one before. The same applies to
inline hashes. Thank you.

In GNU Emacs 31.0.50 (build 1, aarch64-apple-darwin23.5.0, NS
 appkit-2487.60 Version 14.5 (Build 23F79)) of 2024-06-25 built on
 Aarons-MacBook-Pro.local
Windowing system distributor 'Apple', version 10.3.2487
System Description:  macOS 14.5

Configured using:
 'configure --disable-dependency-tracking --disable-silent-rules
 --enable-locallisppath=/opt/homebrew/share/emacs/site-lisp
 --infodir=/opt/homebrew/Cellar/emacs-plus@30/30.0.50/share/info/emacs
 --prefix=/opt/homebrew/Cellar/emacs-plus@30/30.0.50 --with-xml2
 --with-gnutls --with-native-compilation --without-compress-install
 --without-dbus --without-imagemagick --with-modules --with-rsvg
 --with-webp --with-ns --disable-ns-self-contained 'CFLAGS=-Os -w -pipe
 -mmacosx-version-min=14
 -isysroot/Library/Developer/CommandLineTools/SDKs/MacOSX14.sdk
 -DFD_SETSIZE=10000 -DDARWIN_UNLIMITED_SELECT
 -I/opt/homebrew/opt/gcc/include -I/opt/homebrew/opt/libgccjit/include'
 'CPPFLAGS=-I/opt/homebrew/opt/zlib/include
 -I/opt/homebrew/opt/jpeg/include -I/opt/homebrew/opt/icu4c/include
 -I/opt/homebrew/opt/sqlite/include -I/opt/homebrew/opt/readline/include
 -isystem/opt/homebrew/include -F/opt/homebrew/Frameworks
 -isysroot/Library/Developer/CommandLineTools/SDKs/MacOSX14.sdk'
 'LDFLAGS=-L/opt/homebrew/opt/zlib/lib -L/opt/homebrew/opt/jpeg/lib
 -L/opt/homebrew/opt/icu4c/lib -L/opt/homebrew/opt/sqlite/lib
 -L/opt/homebrew/opt/readline/lib -L/opt/homebrew/lib
 -F/opt/homebrew/Frameworks -Wl,-headerpad_max_install_names
 -isysroot/Library/Developer/CommandLineTools/SDKs/MacOSX14.sdk
 -L/opt/homebrew/lib/gcc/14 -I/opt/homebrew/opt/gcc/include
 -I/opt/homebrew/opt/libgccjit/include''

Configured features:
ACL GIF GLIB GMP GNUTLS JPEG LCMS2 LIBXML2 MODULES NATIVE_COMP NOTIFY
KQUEUE NS PDUMPER PNG RSVG SQLITE3 THREADS TIFF TOOLKIT_SCROLL_BARS
TREE_SITTER WEBP XIM ZLIB

Important settings:
  value of $LANG: en_US.UTF-8
  locale-coding-system: utf-8-unix

Major mode: Org

Minor modes in effect:
  consult-notes-denote-mode: t
  windmove-mode: t
  global-evil-mc-mode: t
  evil-mc-mode: t
  global-git-commit-mode: t
  transient-posframe-mode: t
  flyspell-mode: t
  org-indent-mode: t
  org-appear-mode: t
  orgonomic-mode: t
  org-superstar-mode: t
  denote-rename-buffer-mode: t
  denote-menu-bar-mode: t
  xterm-mouse-mode: t
  global-auto-revert-mode: t
  ns-auto-titlebar-mode: t
  global-anzu-mode: t
  anzu-mode: t
  form-feed-mode: t
  eval-sexp-fu-flash-mode: t
  eros-mode: t
  evil-org-mode: t
  speed-of-thought-mode: t
  corfu-prescient-mode: t
  corfu-history-mode: t
  global-flycheck-mode: t
  flycheck-mode: t
  global-evil-surround-mode: t
  evil-surround-mode: t
  gcmh-mode: t
  undo-fu-session-global-mode: t
  undo-fu-session-mode: t
  ws-butler-global-mode: t
  ws-butler-mode: t
  savehist-mode: t
  delete-selection-mode: t
  yas-global-mode: t
  yas-minor-mode: t
  vertico-prescient-mode: t
  prescient-persist-mode: t
  vertico-mouse-mode: t
  vertico-mode: t
  mini-frame-mode: t
  better-jumper-mode: t
  better-jumper-local-mode: t
  save-place-mode: t
  winner-mode: t
  tabspaces-mode: t
  which-key-posframe-mode: t
  which-key-mode: t
  recentf-mode: t
  repeat-mode: t
  modern-tab-bar-mode: t
  +popup-mode: t
  evil-mode: t
  evil-local-mode: t
  server-mode: t
  leader-key-leader-override-mode: t
  global-leader-key-leader-override-mode: t
  elpaca-use-package-mode: t
  override-global-mode: t
  global-display-line-numbers-mode: t
  global-eldoc-mode: t
  show-paren-mode: t
  electric-indent-mode: t
  mouse-wheel-mode: t
  prettify-symbols-mode: t
  tab-bar-mode: t
  file-name-shadow-mode: t
  global-font-lock-mode: t
  font-lock-mode: t
  window-divider-mode: t
  minibuffer-regexp-mode: t
  line-number-mode: t
  auto-fill-function: #[128 \304\300\301.#\207 [yas--auto-fill org-auto-fill-function :around nil apply] 5 advice]
  transient-mark-mode: t
  auto-composition-mode: t
  auto-encryption-mode: t
  auto-compression-mode: t
  abbrev-mode: t

Load-path shadows:
/Users/aaronjensen/.emacs.d/elpaca/builds/lispy/elpa hides /Users/aaronjensen/.emacs.d/elpaca/builds/ivy/elpa
/Users/aaronjensen/.emacs.d/elpaca/builds/which-key/which-key hides /opt/homebrew/Cellar/emacs-plus@30/30.0.50/share/emacs/31.0.50/lisp/which-key

Features:
(shadow mail-extr emacsbug consult-xref dumb-jump popup semantic/ia
semantic/analyze/refs semantic/db-find semantic/db-ref semantic/senator
semantic/decorate pulse semantic/analyze semantic/sort semantic/scope
semantic/analyze/fcn semantic/db eieio-base semantic/ctxt
semantic/format ezimage semantic/tag-ls semantic/find
semantic/util-modes semantic/util semantic semantic/tag cedet yaml-mode
haml-mode css-mode org-mac-link org-capture titlecase titlecase-data
conf-mode sort terraform-mode hcl-mode tramp-cmds wgrep grep embark-org
embark-consult embark ffap typescript-ts-mode hippie-exp evil-numbers
wdired evil-nerd-commenter evil-nerd-commenter-operator
evil-nerd-commenter-sdk sgml-mode facemenu evil-matchit-ruby
ripgrep-capf dabbrev tab-line evil-collection-vterm vterm tramp trampver
tramp-integration tramp-message tramp-compat tramp-loaddefs term ehelp
vterm-module term/xterm xterm diary-lib diary-loaddefs org-clock
cal-move consult-notes-denote consult-notes evil-matchit-simple
evil-matchit-prog evil-matchit evil-matchit-sdk semantic/lex semantic/fw
evil-collection-helpful helpful cc-langs trace cl-print info-look info
elisp-refs files-x consult magit-bookmark bookmark windmove org-goto
speeddating vc-hg vc-bzr vc-src vc-sccs vc-svn vc-cvs vc-rcs log-view
bug-reference magit-extras copy-as-format tabify evil-mc
evil-mc-command-execute evil-mc-command-record evil-mc-cursor-make
evil-mc-region evil-mc-cursor-state evil-mc-undo evil-mc-vars
evil-mc-known-commands evil-mc-common magit-delta xterm-color
evil-collection-magit magit-submodule magit-blame magit-stash
magit-reflog magit-bisect magit-push magit-pull magit-fetch magit-clone
magit-remote magit-commit magit-sequence magit-notes magit-worktree
magit-tag magit-merge magit-branch magit-reset magit-files magit-refs
magit-status magit package url-handlers magit-repos magit-apply
magit-wip magit-log which-func magit-diff smerge-mode diff git-commit
log-edit pcvs-util add-log magit-core magit-autorevert magit-margin
magit-transient magit-process with-editor magit-mode transient-posframe
transient magit-git magit-base magit-section crm hide-mode-line
popup-mode-core flyspell ispell org-indent org-appear orgonomic
org-superstar oc-basic ol-eww eww url-queue mm-url ol-rmail ol-mhe
ol-irc ol-info ol-gnus nnselect gnus-art mm-uu mml2015 mm-view mml-smime
smime dig gnus-sum shr pixel-fill kinsoku url-file svg gnus-group
gnus-undo gnus-start gnus-dbus dbus xml gnus-cloud nnimap nnmail
browse-url mail-source utf7 nnoo parse-time gnus-spec gnus-int
gnus-range message sendmail yank-media rfc822 mml mml-sec mm-decode
mm-bodies mm-encode mailabbrev gmm-utils mailheader gnus-win gnus
nnheader gnus-util mail-utils range ol-docview doc-view image-mode exif
ol-bibtex bibtex iso8601 ol-bbdb ol-w3m ol-doi org-link-doi org-journal
org-crypt epa cal-iso dired-aux denote-rename-buffer denote
evil-collection-dired evil-ruby-text-objects ruby-refactor bundler
inf-ruby ruby-mode evil-terminal-cursor-changer xt-mouse autorevert
ns-auto-titlebar evil-anzu anzu dtrt-indent form-feed eval-sexp-fu eros
lispyville lispy lispy-inline avy etags fileloop evil-collection-edebug
edebug help-fns radix-tree lispy-tags mode-local zoutline org-download
org-attach url-http url-auth mail-parse rfc2231 rfc2047 rfc2045 mm-util
ietf-drums mail-prsvr url-gw async evil-org-agenda evil-org ob-shell
shell ox-odt rng-loc rng-uri rng-parse rng-match rng-dt rng-util
rng-pttrn nxml-parse nxml-ns nxml-enc xmltok nxml-util ox-latex
ox-icalendar org-agenda ox-ascii ox-gfm ox-md ox-html table ox-publish
ox org-element org-persist xdg org-id org-refile org-element-ast
avl-tree generator org-tempo tempo org ob ob-tangle ob-ref ob-lob
ob-table ob-exp org-macro org-src sh-script smie executable ob-comint
org-pcomplete pcomplete org-list org-footnote org-faces org-entities
time-date ob-emacs-lisp ob-core ob-eval org-cycle org-table ol org-fold
org-fold-core org-keys oc org-loaddefs cal-menu calendar cal-loaddefs
org-version org-compat org-macs format-spec elisp-def ert
evil-collection-debug debug backtrace sotlisp skeleton all-the-icons
all-the-icons-faces data-material data-weathericons data-octicons
data-fileicons data-faicons data-alltheicons lsp-diagnostics
lsp-modeline lsp-lens jka-compr cape corfu-prescient corfu-history
evil-collection-corfu corfu lsp-ui lsp-ui-flycheck lsp-ui-doc goto-addr
lsp-ui-imenu lsp-ui-peek lsp-ui-sideline flycheck lsp-ui-util find-func
view lsp-zig lsp-yang lsp-yaml lsp-xml lsp-wgsl lsp-volar lsp-vimscript
lsp-vhdl lsp-vetur lsp-html lsp-verilog lsp-vala lsp-v lsp-typeprof
lsp-ttcn3 lsp-trunk lsp-toml lsp-tilt lsp-tex lsp-terraform lsp-svelte
lsp-steep lsp-sqls lsp-sql lsp-sorbet lsp-solidity lsp-solargraph
lsp-semgrep lsp-rust lsp-ruff-lsp lsp-ruby-syntax-tree lsp-ruby-lsp
lsp-rubocop lsp-roslyn lsp-rf lsp-remark lsp-racket lsp-r lsp-qml
lsp-pylsp lsp-pyls lsp-pwsh lsp-purescript lsp-pls lsp-php
lsp-perlnavigator lsp-perl lsp-openscad lsp-ocaml lsp-nushell lsp-nix
lsp-nim lsp-nginx lsp-move lsp-mojo lsp-mint lsp-meson lsp-mdx
lsp-marksman lsp-markdown lsp-magik lsp-lua lsp-lisp lsp-kotlin lsp-json
lsp-jq lsp-javascript lsp-idris lsp-haxe lsp-hack lsp-groovy lsp-graphql
lsp-golangci-lint lsp-glsl lsp-gleam lsp-gdscript lsp-fsharp lsp-fortran
lsp-eslint lsp-erlang lsp-emmet lsp-elm lsp-elixir lsp-earthly
lsp-dockerfile lsp-dhall lsp-d lsp-cypher lsp-cucumber lsp-css
lsp-csharp gnutls lsp-crystal lsp-credo lsp-cobol lsp-cmake lsp-clojure
lsp-clangd dom lsp-bufls lsp-go lsp-completion lsp-beancount lsp-bash
lsp-awk lsp-autotools lsp-astro lsp-asm lsp-ansible lsp-angular lsp-ada
lsp-semantic-tokens lsp-actionscript lsp-mode lsp-protocol
evil-collection-xref xref spinner network-stream puny nsm markdown-mode
color noutline outline inline ht filenotify f s ewoc epg rfc6068
epg-config dash compile text-property-search comint ansi-osc elec-pair
envrc inheritenv ansi-color evil-surround evil-matchit-evil-setup js
c-ts-common treesit imenu cc-mode cc-fonts cc-guess cc-menus cc-cmds
cc-styles cc-align cc-engine cc-vars cc-defs gcmh undo-fu-session
ws-butler vc-git diff-mode track-changes vertico-directory cursor-sensor
savehist delsel yasnippet vertico-prescient prescient char-fold
vertico-mouse vertico mini-frame better-jumper saveplace winner
tabspaces dired-x dired dired-loaddefs vc vc-dispatcher popup-mode-hacks
which-key-posframe posframe evil-collection-which-key which-key recentf
tree-widget repeat project orderless modern-tab-bar popup-mode
popup-mode-settings evil-collection-elpaca evil-collection annalist
evil-little-word cus-edit cus-start cus-load wid-edit pp evil
evil-integration evil-maps evil-commands evil-digraphs reveal evil-jumps
evil-command-window evil-types evil-search evil-ex evil-macros
evil-repeat evil-states evil-core advice evil-common thingatpt rect
evil-vars memoize nano-modeline nano-theme face-remap nano-theme-support
disp-table gcmh-autoloads copy-as-format-autoloads pdf-tools-autoloads
tablist-autoloads restclient-autoloads vterm-autoloads
dumb-jump-autoloads popup-autoloads haml-mode-autoloads
emmet-mode-autoloads terraform-mode-autoloads hcl-mode-autoloads
dockerfile-mode-autoloads yaml-mode-autoloads json-mode-autoloads
json-snatcher-autoloads grip-mode-autoloads lua-mode-autoloads
bundler-autoloads inf-ruby-autoloads ruby-refactor-autoloads
evil-ruby-text-objects-autoloads sotlisp-autoloads elisp-def-autoloads
lispyville-autoloads lispy-autoloads iedit-autoloads swiper-autoloads
ivy-autoloads zoutline-autoloads eros-autoloads eval-sexp-fu-autoloads
web-mode-autoloads ripgrep-capf-autoloads git-link-autoloads
consult-git-commit-autoloads git-timemachine-autoloads
magit-delta-autoloads xterm-color-autoloads prettier-autoloads
iter2-autoloads nvm-autoloads flycheck-autoloads lsp-ui-autoloads
lsp-mode-autoloads spinner-autoloads markdown-mode-autoloads
consult-notes-autoloads denote-autoloads imenu-list-autoloads
org-superstar-autoloads ox-gfm-autoloads org-pandoc-import-autoloads
gnuplot-autoloads org-download-autoloads async-autoloads
org-journal-autoloads orgonomic-autoloads org-drill-autoloads
persist-autoloads org-appear-autoloads org-mac-link-autoloads
evil-org-autoloads evil-terminal-cursor-changer-autoloads
transient-posframe-autoloads better-jumper-autoloads
buffer-move-autoloads rotate-autoloads mini-frame-autoloads
embark-consult-autoloads embark-autoloads consult-autoloads
orderless-autoloads cape-autoloads corfu-prescient-autoloads
corfu-autoloads vertico-prescient-autoloads vertico-autoloads
prescient-autoloads tabspaces-autoloads modern-tab-bar-autoloads
which-key-posframe-autoloads which-key-autoloads popup-mode-autoloads
hide-mode-line-autoloads evil-anzu-autoloads anzu-autoloads
titlecase-autoloads wgrep-autoloads yasnippet-autoloads
form-feed-autoloads drag-stuff-autoloads dtrt-indent-autoloads
ws-butler-autoloads evil-collection-autoloads annalist-autoloads
evil-mc-autoloads evil-numbers-autoloads speeddating-autoloads
evil-little-word-autoloads evil-matchit-autoloads
evil-nerd-commenter-autoloads evil-visualstar-autoloads
evil-surround-autoloads vundo-autoloads undo-fu-session-autoloads
ztree-autoloads dwim-shell-command-autoloads treemacs-tab-bar-autoloads
treemacs-magit-autoloads magit-autoloads git-commit-autoloads
magit-section-autoloads with-editor-autoloads treemacs-evil-autoloads
evil-autoloads goto-chg-autoloads treemacs-autoloads
ace-window-autoloads avy-autoloads pfuture-autoloads ht-autoloads
cfrs-autoloads all-the-icons-autoloads rainbow-mode-autoloads
posframe-autoloads ns-auto-titlebar-autoloads nano-modeline-autoloads
nano-theme-autoloads memoize-autoloads envrc-autoloads
inheritenv-autoloads helpful-autoloads f-autoloads elisp-refs-autoloads
s-autoloads dired-subtree-autoloads dired-hacks-utils-autoloads
dash-autoloads server pcase hydra ring lv edmacro kmacro compdef derived
compdef-autoloads hydra-autoloads lv-autoloads leader-key bind-map
leader-key-autoloads bind-map-autoloads no-littering compat
no-littering-autoloads elpaca-use-package use-package use-package-ensure
use-package-delight use-package-diminish use-package-bind-key bind-key
easy-mmode use-package-core elpaca-use-package-autoloads elpaca-log
elpaca-ui url url-proxy url-privacy url-expand url-methods url-history
url-cookie generate-lisp-file url-domsuf url-util url-parse auth-source
eieio eieio-core password-cache json map byte-opt url-vars mailcap
comp-run cl-macs elpaca elpaca-process elpaca-autoloads comp cl-seq
comp-cstr comp-common warnings subr-x rx gv bytecomp byte-compile
cl-extra help-mode icons cl-loaddefs cl-lib display-line-numbers rmc
iso-transl tooltip cconv eldoc paren electric uniquify ediff-hook
vc-hooks lisp-float-type elisp-mode mwheel term/ns-win ns-win
ucs-normalize mule-util term/common-win tool-bar dnd fontset image
regexp-opt fringe tabulated-list replace newcomment text-mode lisp-mode
prog-mode register page tab-bar menu-bar rfn-eshadow isearch easymenu
timer select scroll-bar mouse jit-lock font-lock syntax font-core
term/tty-colors frame minibuffer nadvice seq simple cl-generic
indonesian philippine cham georgian utf-8-lang misc-lang vietnamese
tibetan thai tai-viet lao korean japanese eucjp-ms cp51932 hebrew greek
romanian slovak czech european ethiopic indian cyrillic chinese
composite emoji-zwj charscript charprop case-table epa-hook
jka-cmpr-hook help abbrev obarray oclosure cl-preloaded button loaddefs
theme-loaddefs faces cus-face macroexp files window text-properties
overlay sha1 md5 base64 format env code-pages mule custom widget keymap
hashtable-print-readable backquote threads kqueue cocoa ns lcms2
multi-tty make-network-process native-compile emacs)

Memory information:
((conses 16 3149198 4496413) (symbols 48 78066 369) (strings 32 483848 118203)
 (string-bytes 1 13020713) (vectors 16 159568) (vector-slots 8 2730673 1653009)
 (floats 8 2113 13567) (intervals 56 187870 16167) (buffers 992 190))