Skip to content

Commit

Permalink
fix: fixes examples command in the cli
Browse files Browse the repository at this point in the history
  • Loading branch information
qharlie committed Mar 21, 2022
1 parent b1bf0a8 commit 30d2b2f
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 6 deletions.
2 changes: 1 addition & 1 deletion pyprql/assets/cli_bottom_toolbar.txt
@@ -1 +1 @@
Tab to complete suggestions (in white). Ctrl-f to complete history (in grey). Up and down for history. Type help for more.
Tab to complete suggestions (in white). Alt-f to complete history (in grey). Up and down for history. Type help for more.
10 changes: 6 additions & 4 deletions pyprql/assets/prql_mode_help.txt
Expand Up @@ -10,7 +10,9 @@ Commands:
Command [cornflower_blue bold]examples[/cornflower_blue bold]: Displays sql-to-prql examples for reference

Editor:
Key [cornflower_blue bold]tab[/cornflower_blue bold] completes auto complete suggestions ( [white bold]from a list[/white bold] )
Key [cornflower_blue bold]Ctrl+f[/cornflower_blue bold] completes history ( [light_slate_gray]in grey[/light_slate_gray] )
Key [cornflower_blue bold]Up and Down[/cornflower_blue bold] navigates the history
Key [cornflower_blue bold]Ctrl+a/Ctrl+e[/cornflower_blue bold] home / end , ( emacs keybindings )
Key [tan bold]tab[/tan bold] completes auto complete suggestions ( [white bold]from a list[/white bold] )
Key [tan bold]Alt+f[/tan bold] completes history ( [light_slate_gray]in grey[/light_slate_gray] )
Key [tan bold]Up and Down[/tan bold] navigates the history
Key [tan bold]Ctrl+a/Ctrl+e[/tan bold] home / end , ( emacs keybindings )
Key [tan bold]Ctrl+k[/tan bold] kill line forward from cursor
Key [tan bold]Ctrl+l[/tan bold] clear screen
2 changes: 1 addition & 1 deletion pyprql/cli/cli.py
Expand Up @@ -396,7 +396,7 @@ def handle_input(self, _user_input: str) -> None:
sys.exit(0)
elif user_input == "examples":
# That would likely increase maintainability
rich.print(prql.read_file("examples.txt", this_files_path))
rich.print(prql.read_file("../assets/examples.txt", this_files_path))
return
elif user_input == "?" or user_input == "help":
rich.print("PyPRQL version: {}".format(pyprql_version))
Expand Down

0 comments on commit 30d2b2f

Please sign in to comment.