Skip to content

Commit 310650c

Browse files
authored
Add workspace category (#661)
* Create a new Workspace command category * Update readme
1 parent 9790517 commit 310650c

File tree

3 files changed

+9
-7
lines changed

3 files changed

+9
-7
lines changed

README.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -84,14 +84,15 @@ Hello World
8484

8585
The following commands are available on IRB. You can get the same output from the `show_cmds` command.
8686

87-
8887
```
89-
IRB
88+
Workspace
9089
cwws Show the current workspace.
9190
chws Change the current workspace to an object.
9291
workspaces Show workspaces.
9392
pushws Push an object to the workspace stack.
9493
popws Pop a workspace from the workspace stack.
94+
95+
IRB
9596
irb_load Load a Ruby file.
9697
irb_require Require a Ruby file.
9798
source Loads a given file in the current session.
@@ -119,6 +120,7 @@ Misc
119120
measure `measure` enables the mode to measure processing time. `measure :off` disables it.
120121
121122
Context
123+
help [DEPRECATED] Enter the mode to look up RI documents.
122124
show_doc Enter the mode to look up RI documents.
123125
ls Show methods, constants, and variables. `-g [query]` or `-G [query]` allows you to filter out the output.
124126
show_source Show the source code of a given method or constant.

lib/irb/cmd/chws.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ module IRB
1313
module ExtendCommand
1414

1515
class CurrentWorkingWorkspace < Nop
16-
category "IRB"
16+
category "Workspace"
1717
description "Show the current workspace."
1818

1919
def execute(*obj)
@@ -22,7 +22,7 @@ def execute(*obj)
2222
end
2323

2424
class ChangeWorkspace < Nop
25-
category "IRB"
25+
category "Workspace"
2626
description "Change the current workspace to an object."
2727

2828
def execute(*obj)

lib/irb/cmd/pushws.rb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ module IRB
1212

1313
module ExtendCommand
1414
class Workspaces < Nop
15-
category "IRB"
15+
category "Workspace"
1616
description "Show workspaces."
1717

1818
def execute(*obj)
@@ -21,7 +21,7 @@ def execute(*obj)
2121
end
2222

2323
class PushWorkspace < Workspaces
24-
category "IRB"
24+
category "Workspace"
2525
description "Push an object to the workspace stack."
2626

2727
def execute(*obj)
@@ -31,7 +31,7 @@ def execute(*obj)
3131
end
3232

3333
class PopWorkspace < Workspaces
34-
category "IRB"
34+
category "Workspace"
3535
description "Pop a workspace from the workspace stack."
3636

3737
def execute(*obj)

0 commit comments

Comments
 (0)