RubyGems Navigation menu

make_menu 0.0.2

Creates a number-selection menu from a Makefile. The menu will attempt to fill the width of the terminal window. - Any targets in the Makefile with a double-hash comment will be displayed, e.g.: serve: ## Start Rails server in background This will display a line such as '1. Start Rails server in background' which runs the command `make serve`. - A line that starts with a triple-hash will create a new menu group, e.g.: ### Docker Commands This will begin a new group with the header 'Docker Commands' - The environment variable MENU can be used to specify a custom menu class, e.g.: export MENU=Accounts This assumes that a class `AccountsMenu` is defined in the file `accounts_menu.rb` You can define two constants in your custom class: LOGO (String) text or ASCII art to display above the menu HIGHLIGHTS (Hash{String=>[Symbol,Array]}) Add coloring to specific words or phrases - The environment variable MAKEFILE can specify a Makefile. The default is './Makefile'. The menu will not display any targets called 'menu' or 'status'. The latter, if present, is called each time the menu displays. ----------------------------- Docker Container Status Panel ----------------------------- Displays a color-coded panel indicating whether or not a Docker container is running. You must define a custom class inheriting from `MakeMenu::StatusPanel` and indicate this using the environment variable MENU, e.g.: export MENU=Accounts This assumes that a class `AccountsStatusPanel` is defined in the file `accounts_status_panel.rb` You can define a constant CONTAINERS {String=>String} in this custom class to map the displayed label to the container name, e.g.: CONTAINERS = { 'Backend' => 'myapp-backend-1' }

Gemfile:
= 复制到剪贴板 已复制!

安装:
=

版本列表:

  1. 2.1.1 - February 15, 2024 (10.5 KB)
  2. 2.1.0 - February 07, 2024 (10.5 KB)
  3. 2.0.0 - January 10, 2024 (10.0 KB)
  4. 1.1.0 - January 09, 2024 (10.0 KB)
  5. 1.0.0 - January 07, 2024 (9.5 KB)
  6. 0.0.2 - December 20, 2023 (11.5 KB)
显示所有版本 (共 11 个)

Runtime 依赖 (1):

tty-screen ~> 0.8.2

业主:

推送:

作者:

  • Barri Mason

SHA 256 校验和:

= 复制到剪贴板 已复制!

下载总量 3,419

这个版本 231

许可:

MIT

需要的 Ruby 版本: >= 0

链接: