Make ds an alias for dropshell!
This commit is contained in:
parent
5d7a22794d
commit
63144032c1
@ -51,12 +51,32 @@ install(TARGETS dropshell
|
||||
RUNTIME DESTINATION bin
|
||||
)
|
||||
|
||||
# Create symbolic link 'ds' pointing to 'dropshell'
|
||||
install(CODE "
|
||||
message(STATUS \"Creating symlink: ds -> dropshell\")
|
||||
execute_process(
|
||||
COMMAND ${CMAKE_COMMAND} -E create_symlink
|
||||
\${CMAKE_INSTALL_PREFIX}/bin/dropshell
|
||||
\${CMAKE_INSTALL_PREFIX}/bin/ds
|
||||
)
|
||||
")
|
||||
|
||||
# Install completion script
|
||||
install(FILES src/dropshell-completion.bash
|
||||
DESTINATION /etc/bash_completion.d
|
||||
RENAME dropshell
|
||||
)
|
||||
|
||||
# Create a symlink for the completion script to work with 'ds' command
|
||||
install(CODE "
|
||||
message(STATUS \"Creating completion script symlink for 'ds'\")
|
||||
execute_process(
|
||||
COMMAND ${CMAKE_COMMAND} -E create_symlink
|
||||
/etc/bash_completion.d/dropshell
|
||||
/etc/bash_completion.d/ds
|
||||
)
|
||||
")
|
||||
|
||||
# Create pre-install script to clean old templates
|
||||
install(CODE "
|
||||
message(STATUS \"Removing old template files...\")
|
||||
|
@ -48,4 +48,5 @@ _dropshell_completions() {
|
||||
}
|
||||
|
||||
# Register the completion function
|
||||
complete -F _dropshell_completions dropshell
|
||||
complete -F _dropshell_completions dropshell
|
||||
complete -F _dropshell_completions ds
|
Loading…
x
Reference in New Issue
Block a user