[ci skip] Add a work-in-progress bash-completion shell script.
This commit is contained in:
parent
15439d8b3e
commit
7ccb83dfce
|
@ -40,6 +40,7 @@ add_executable(ybcon src/main.cpp resources/Yerbacon.rc src/parser/MainParse.cpp
|
|||
|
||||
# lpkg = linux package, wpkg = windows package
|
||||
if (UNIX AND NOT MINGW)
|
||||
include(GNUInstallDirs)
|
||||
set(CPACK_PACKAGING_INSTALL_PREFIX "/opt")
|
||||
set(CPACK_PACKAGE_FILE_NAME "${CPACK_PACKAGE_FILE_NAME}_lpkg")
|
||||
set(CPACK_SYSTEM_NAME "Linux-${CMAKE_CXX_COMPILER_ARCHITECTURE_ID}")
|
||||
|
@ -54,6 +55,7 @@ if (UNIX AND NOT MINGW)
|
|||
if (NOT DEFINED CPACK_GENERATOR)
|
||||
set(CPACK_GENERATOR TGZ;STGZ;RPM;DEB)
|
||||
endif()
|
||||
install(FILES ${CMAKE_CURRENT_SOURCE_DIR}/scripts/bash-completion.sh DESTINATION ${CMAKE_INSTALL_SYSCONFDIR}/ybcon.d)
|
||||
install(FILES ${CMAKE_CURRENT_BINARY_DIR}/ybcon ${CMAKE_CURRENT_SOURCE_DIR}/scripts/ybcon.sh
|
||||
PERMISSIONS
|
||||
OWNER_WRITE
|
||||
|
|
|
@ -0,0 +1 @@
|
|||
# Bash autocomplete script for yerbacon
|
|
@ -1,3 +1,10 @@
|
|||
#!/usr/bin/sh
|
||||
#!/bin/sh
|
||||
|
||||
# Post install ybcon script
|
||||
|
||||
ln -sf /opt/bin/ybcon.sh /usr/bin/ybcon
|
||||
|
||||
bashcompleteLoc="/etc/bash_completion.d"
|
||||
if [ -d $bashcompleteLoc ]; then
|
||||
ln -sf /opt/etc/ybcon.d/bash-completion.sh "$bashcompleteLoc/ybcon.sh"
|
||||
fi
|
Loading…
Reference in New Issue