You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@celix.apache.org by pn...@apache.org on 2018/07/10 12:00:28 UTC
celix git commit: CELIX-451: Add celix_bundle_add_files CMake command
Repository: celix
Updated Branches:
refs/heads/develop c4de9077d -> 8109f6ca7
CELIX-451: Add celix_bundle_add_files CMake command
- Also rename celix_bundle_dir to celix_bundle_add_dir
- Refactors location of some the CMake generated files, so that everything is generated in celix/gen/
Project: http://git-wip-us.apache.org/repos/asf/celix/repo
Commit: http://git-wip-us.apache.org/repos/asf/celix/commit/8109f6ca
Tree: http://git-wip-us.apache.org/repos/asf/celix/tree/8109f6ca
Diff: http://git-wip-us.apache.org/repos/asf/celix/diff/8109f6ca
Branch: refs/heads/develop
Commit: 8109f6ca76b569aaaba2fe4f16a5e10eb05523da
Parents: c4de907
Author: Pepijn Noltes <pe...@gmail.com>
Authored: Tue Jul 10 13:58:30 2018 +0200
Committer: Pepijn Noltes <pe...@gmail.com>
Committed: Tue Jul 10 13:58:30 2018 +0200
----------------------------------------------------------------------
CMakeLists.txt | 4 +-
cmake/cmake_celix/BundlePackaging.cmake | 81 ++++++++++++++++----
cmake/cmake_celix/ContainerPackaging.cmake | 14 ++--
cmake/cmake_celix/DockerPackaging.cmake | 8 +-
documents/cmake_commands/readme.md | 5 +-
examples/celix-examples/civetweb/CMakeLists.txt | 4 +-
.../civetweb/resources/index.html | 3 +-
.../celix-examples/civetweb/resources/script.js | 1 +
8 files changed, 87 insertions(+), 33 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/celix/blob/8109f6ca/CMakeLists.txt
----------------------------------------------------------------------
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 06c4000..36656e9 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -79,9 +79,9 @@ install(DIRECTORY ${CMAKE_SOURCE_DIR}/cmake/cmake_celix/ DESTINATION share/celix
#configure and install CelixConfig and CelixConfigVersion files
configure_file(cmake/CelixConfigVersion.cmake.in
- "${PROJECT_BINARY_DIR}/celix/gen/CelixConfigVersion.cmake" @ONLY)
+ "${PROJECT_BINARY_DIR}/celix/gen/cmake/CelixConfigVersion.cmake" @ONLY)
install(FILES
"cmake/CelixConfig.cmake"
- "${PROJECT_BINARY_DIR}/celix/gen/CelixConfigVersion.cmake"
+ "${PROJECT_BINARY_DIR}/celix/gen/cmake/CelixConfigVersion.cmake"
DESTINATION "${CMAKE_INSTALL_LIBDIR}/cmake/Celix" COMPONENT cmake)
http://git-wip-us.apache.org/repos/asf/celix/blob/8109f6ca/cmake/cmake_celix/BundlePackaging.cmake
----------------------------------------------------------------------
diff --git a/cmake/cmake_celix/BundlePackaging.cmake b/cmake/cmake_celix/BundlePackaging.cmake
index 35f5c0a..8236bcc 100644
--- a/cmake/cmake_celix/BundlePackaging.cmake
+++ b/cmake/cmake_celix/BundlePackaging.cmake
@@ -134,8 +134,10 @@ function(add_celix_bundle)
endif ()
set(BUNDLE_FILE "${CMAKE_CURRENT_BINARY_DIR}/${BUNDLE_FILENAME}")
- set(BUNDLE_CONTENT_DIR "${CMAKE_CURRENT_BINARY_DIR}/${BUNDLE_TARGET_NAME}_content")
- set(BUNDLE_GEN_DIR "${CMAKE_CURRENT_BINARY_DIR}/${BUNDLE_TARGET_NAME}_gen")
+ #set(BUNDLE_CONTENT_DIR "${CMAKE_CURRENT_BINARY_DIR}/${BUNDLE_TARGET_NAME}_content")
+ #set(BUNDLE_GEN_DIR "${CMAKE_CURRENT_BINARY_DIR}/${BUNDLE_TARGET_NAME}_gen")
+ set(BUNDLE_CONTENT_DIR "${CMAKE_BINARY_DIR}/celix/gen/bundles/${BUNDLE_TARGET_NAME}/content")
+ set(BUNDLE_GEN_DIR "${CMAKE_BINARY_DIR}/celix/gen/bundles/${BUNDLE_TARGET_NAME}")
###### Setting up dependency for bundles target
@@ -217,7 +219,7 @@ function(add_celix_bundle)
#############################
### BUNDLE TARGET PROPERTIES
#############################
- #alreadyer set
+ #already set
# BUNDLE_TARGET_IS_LIB -> true (can be use to test if target is bundle target
# BUNDLE_TARGET -> refers to the _bundle target which is responsible for building the zip file
#internal use
@@ -225,7 +227,7 @@ function(add_celix_bundle)
set_target_properties(${BUNDLE_TARGET_NAME} PROPERTIES "BUNDLE_DEPEND_TARGETS" "") #bundle target dependencies. Note can be extended after the add_bundle call
set_target_properties(${BUNDLE_TARGET_NAME} PROPERTIES "BUNDLE_GEN_DIR" ${BUNDLE_GEN_DIR}) #location for generated output.
set_target_properties(${BUNDLE_TARGET_NAME} PROPERTIES "BUNDLE_CREATE_BUNDLE_TARGET" ${BUNDLE_TARGET_NAME}_bundle) #target which creat the bundle zip
- set_target_properties(${BUNDLE_TARGET_NAME} PROPERTIES "BUNDLE_IMPORTED" FALSE) #whethet target is a imported (bundle) target
+ set_target_properties(${BUNDLE_TARGET_NAME} PROPERTIES "BUNDLE_IMPORTED" FALSE) #whether targer is a imported (bundle) target
#bundle specific
set_target_properties(${BUNDLE_TARGET_NAME} PROPERTIES "BUNDLE_CONTENT_DIR" ${BUNDLE_CONTENT_DIR}) #location where the content to be jar/zipped.
@@ -438,8 +440,8 @@ function(celix_bundle_files)
file(COPY ${FILES_UNPARSED_ARGUMENTS} DESTINATION ${DESTINATION})
endfunction()
-#Note celix_bundle_dir copies the dir and can track changes.
-function(celix_bundle_dir)
+#Note celix_bundle_add_dir copies the dir and can track changes.
+function(celix_bundle_add_dir)
#0 is bundle TARGET
list(GET ARGN 0 BUNDLE)
list(REMOVE_AT ARGN 0)
@@ -459,16 +461,23 @@ function(celix_bundle_dir)
get_target_property(BUNDLE_DIR ${BUNDLE} "BUNDLE_CONTENT_DIR")
if (NOT COPY_DESTINATION)
- set(DESTINATION "${BUNDLE_DIR}/${FILES_DESTINATION}")
- else()
set(DESTINATION "${BUNDLE_DIR}")
+ else()
+ set(DESTINATION "${BUNDLE_DIR}/${COPY_DESTINATION}")
endif()
- set(COPY_CMAKE_SCRIPT "${CMAKE_BINARY_DIR}/celix/gen/bundles/${BUNDLE}/copy-${INPUT_DIR}.cmake")
- file(WRITE ${COPY_CMAKE_SCRIPT}
- "file(COPY ${CMAKE_CURRENT_LIST_DIR}/${INPUT_DIR} DESTINATION ${DESTINATION})")
+ string(UUID COPY_ID NAMESPACE "661ee07c-842d-11e8-adfc-80fa5b02e11b" NAME "${INPUT_DIR}" TYPE MD5)
- set(TIMESTAMP "${CMAKE_BINARY_DIR}/celix/gen/bundles/${BUNDLE}/copy-${INPUT_DIR}.timestamp")
+ set(COPY_CMAKE_SCRIPT "${CMAKE_BINARY_DIR}/celix/gen/bundles/${BUNDLE}/copy-dir-${COPY_ID}.cmake")
+ if (IS_ABSOLUTE ${INPUT_DIR})
+ file(WRITE ${COPY_CMAKE_SCRIPT}
+ "file(COPY ${INPUT_DIR} DESTINATION ${DESTINATION})")
+ else()
+ file(WRITE ${COPY_CMAKE_SCRIPT}
+ "file(COPY ${CMAKE_CURRENT_LIST_DIR}/${INPUT_DIR} DESTINATION ${DESTINATION})")
+ endif()
+
+ set(TIMESTAMP "${CMAKE_BINARY_DIR}/celix/gen/bundles/${BUNDLE}/copy-dir-${COPY_ID}.timestamp")
file(GLOB DIR_FILES ${INPUT_DIR})
add_custom_command(OUTPUT ${TIMESTAMP}
COMMAND ${CMAKE_COMMAND} -E touch ${TIMESTAMP}
@@ -482,6 +491,50 @@ function(celix_bundle_dir)
set_target_properties(${BUNDLE} PROPERTIES "BUNDLE_DEPEND_TARGETS" "${DEPS}")
endfunction()
+function(celix_bundle_add_files)
+ #0 is bundle TARGET
+ list(GET ARGN 0 BUNDLE)
+ list(REMOVE_AT ARGN 0)
+
+ set(OPTIONS )
+ set(ONE_VAL_ARGS DESTINATION)
+ set(MULTI_VAL_ARGS FILES)
+ cmake_parse_arguments(COPY "${OPTIONS}" "${ONE_VAL_ARGS}" "${MULTI_VAL_ARGS}" ${ARGN})
+
+ get_target_property(BUNDLE_DIR ${BUNDLE} "BUNDLE_CONTENT_DIR")
+ if (NOT COPY_DESTINATION)
+ set(DESTINATION "${BUNDLE_DIR}")
+ else()
+ set(DESTINATION "${BUNDLE_DIR}/${COPY_DESTINATION}")
+ endif()
+
+ string(UUID COPY_ID NAMESPACE "661ee07c-842d-11e8-adfc-80fa5b02e11b" NAME "${COPY_FILES}" TYPE MD5)
+
+ set(TIMESTAMP "${CMAKE_BINARY_DIR}/celix/gen/bundles/${BUNDLE}/copy-files-${COPY_ID}.timestamp")
+ set(COPY_CMAKE_SCRIPT "${CMAKE_BINARY_DIR}/celix/gen/bundles/${BUNDLE}/copy-files-${COPY_ID}.cmake")
+ file(WRITE ${COPY_CMAKE_SCRIPT}
+ "#Copy script, copies the file on a file per file base\n")
+ foreach(FILE IN ITEMS ${COPY_FILES})
+ if (IS_ABSOLUTE ${FILE})
+ file(APPEND ${COPY_CMAKE_SCRIPT}
+ "file(COPY ${FILE} DESTINATION ${DESTINATION})\n")
+ else()
+ file(APPEND ${COPY_CMAKE_SCRIPT}
+ "file(COPY ${CMAKE_CURRENT_LIST_DIR}/${FILE} DESTINATION ${DESTINATION})\n")
+ endif()
+ endforeach()
+ add_custom_command(OUTPUT ${TIMESTAMP}
+ COMMAND ${CMAKE_COMMAND} -E touch ${TIMESTAMP}
+ COMMAND ${CMAKE_COMMAND} -P ${COPY_CMAKE_SCRIPT}
+ DEPENDS ${COPY_FILES}
+ COMMENT "Copying files to ${DESTINATION}"
+ )
+
+ get_target_property(DEPS ${BUNDLE} "BUNDLE_DEPEND_TARGETS")
+ list(APPEND DEPS "${TIMESTAMP}")
+ set_target_properties(${BUNDLE} PROPERTIES "BUNDLE_DEPEND_TARGETS" "${DEPS}")
+endfunction()
+
function(bundle_headers)
message(DEPRECATION "bundle_headers is deprecated, use celix_bundle_headers instead.")
celix_bundle_headers(${ARGN})
@@ -615,8 +668,8 @@ function(install_celix_bundle_targets)
string(REGEX MATCHALL "/" SLASH_MATCHES ${DEST_PATH})
list(LENGTH SLASH_MATCHES NR_OF_SUB_DIRS)
- set(CONF_IN_FILE "${CMAKE_BINARY_DIR}/celix/gen/${EXPORT_NAME}-ImportedBundleTargets.cmake.in")
- set(CONF_FILE "${CMAKE_BINARY_DIR}/celix/gen/${EXPORT_NAME}-ImportedBundleTargets.cmake")
+ set(CONF_IN_FILE "${CMAKE_BINARY_DIR}/celix/gen/cmake/${EXPORT_NAME}-ImportedBundleTargets.cmake.in")
+ set(CONF_FILE "${CMAKE_BINARY_DIR}/celix/gen/cmake/${EXPORT_NAME}-ImportedBundleTargets.cmake")
file(REMOVE "${CONF_IN_FILE}")
http://git-wip-us.apache.org/repos/asf/celix/blob/8109f6ca/cmake/cmake_celix/ContainerPackaging.cmake
----------------------------------------------------------------------
diff --git a/cmake/cmake_celix/ContainerPackaging.cmake b/cmake/cmake_celix/ContainerPackaging.cmake
index 9379d39..b39cdae 100644
--- a/cmake/cmake_celix/ContainerPackaging.cmake
+++ b/cmake/cmake_celix/ContainerPackaging.cmake
@@ -81,16 +81,16 @@ function(add_celix_container)
endif()
elseif (CONTAINER_LAUNCHER_SRC)
get_filename_component(SRC_FILENAME ${CONTAINER_LAUNCHER_SRC} NAME)
- set(LAUNCHER_SRC "${PROJECT_BINARY_DIR}/celix/gen/${CONTAINER_TARGET}/${SRC_FILENAME}")
+ set(LAUNCHER_SRC "${PROJECT_BINARY_DIR}/celix/gen/containers/${CONTAINER_TARGET}/${SRC_FILENAME}")
set(LAUNCHER_ORG "${CONTAINER_LAUNCHER_SRC}")
add_custom_command(OUTPUT ${LAUNCHER_SRC}
COMMAND ${CMAKE_COMMAND} -E copy_if_different ${LAUNCHER_ORG} ${LAUNCHER_SRC}
)
else () #generate custom launcher
if (CONTAINER_CXX)
- set(LAUNCHER_SRC "${PROJECT_BINARY_DIR}/celix/gen/${CONTAINER_TARGET}/main.cc")
+ set(LAUNCHER_SRC "${PROJECT_BINARY_DIR}/celix/gen/containers/${CONTAINER_TARGET}/main.cc")
else()
- set(LAUNCHER_SRC "${PROJECT_BINARY_DIR}/celix/gen/${CONTAINER_TARGET}/main.c")
+ set(LAUNCHER_SRC "${PROJECT_BINARY_DIR}/celix/gen/containers/${CONTAINER_TARGET}/main.c")
endif()
file(GENERATE
@@ -122,7 +122,7 @@ $<JOIN:$<TARGET_PROPERTY:${CONTAINER_TARGET},CONTAINER_EMBEDDED_PROPERTIES>,\\n\
endif ()
#generate config.properties
- set(STAGE1_PROPERTIES "${PROJECT_BINARY_DIR}/celix/gen/${CONTAINER_TARGET}/container-config-stage1.properties")
+ set(STAGE1_PROPERTIES "${PROJECT_BINARY_DIR}/celix/gen/containers/${CONTAINER_TARGET}/container-config-stage1.properties")
file(GENERATE
OUTPUT "${STAGE1_PROPERTIES}"
CONTENT "CELIX_AUTO_START_0=$<JOIN:$<TARGET_PROPERTY:${CONTAINER_TARGET},CONTAINER_BUNDLES_LEVEL_0>, >
@@ -264,7 +264,7 @@ function(celix_container_bundles_dir)
get_target_property(IMP ${BUNDLE} BUNDLE_IMPORTED)
if (IMP) #An imported bundle target -> handle target without DEPENDS
string(MAKE_C_IDENTIFIER ${BUNDLE} BUNDLE_ID) #Create id with no special chars (e.g. for target like Celix::shell)
- set(OUT "${CMAKE_BINARY_DIR}/celix/gen/${CONTAINER_TARGET}/copy-bundle-for-target-${BUNDLE_ID}.timestamp")
+ set(OUT "${CMAKE_BINARY_DIR}/celix/gen/containers/${CONTAINER_TARGET}/copy-bundle-for-target-${BUNDLE_ID}.timestamp")
set(DEST "${CONTAINER_LOC}/${BD_DIR_NAME}/$<TARGET_PROPERTY:${BUNDLE},BUNDLE_FILENAME>")
add_custom_command(OUTPUT ${OUT}
COMMAND ${CMAKE_COMMAND} -E touch ${OUT}
@@ -279,7 +279,7 @@ function(celix_container_bundles_dir)
if (NOT HANDLED) #not a imported bundle target so (assuming) a future bundle target
string(MAKE_C_IDENTIFIER ${BUNDLE} BUNDLE_ID) #Create id with no special chars (e.g. for target like Celix::shell)
- set(OUT "${CMAKE_BINARY_DIR}/celix/gen/${CONTAINER_TARGET}/copy-bundle-for-target-${BUNDLE_ID}.timestamp")
+ set(OUT "${CMAKE_BINARY_DIR}/celix/gen/containers/${CONTAINER_TARGET}/copy-bundle-for-target-${BUNDLE_ID}.timestamp")
set(DEST "${CONTAINER_LOC}/${BD_DIR_NAME}/$<TARGET_PROPERTY:${BUNDLE},BUNDLE_FILENAME>")
add_custom_command(OUTPUT ${OUT}
COMMAND ${CMAKE_COMMAND} -E touch ${OUT}
@@ -347,7 +347,7 @@ function(celix_container_bundles)
if (NOT COPY) #in case of COPY dep will be added in celix_container_bundles_dir
string(MAKE_C_IDENTIFIER ${BUNDLE} BUNDLE_ID) #Create id with no special chars (e.g. for target like Celix::shell)
- set(OUT "${CMAKE_BINARY_DIR}/celix/gen/${CONTAINER_TARGET}/check-bundle-for-target-${BUNDLE_ID}.timestamp")
+ set(OUT "${CMAKE_BINARY_DIR}/celix/gen/containers/${CONTAINER_TARGET}/check-bundle-for-target-${BUNDLE_ID}.timestamp")
add_custom_command(OUTPUT ${OUT}
COMMAND ${CMAKE_COMMAND} -E touch ${OUT}
DEPENDS ${BUNDLE} $<TARGET_PROPERTY:${BUNDLE},BUNDLE_CREATE_BUNDLE_TARGET>
http://git-wip-us.apache.org/repos/asf/celix/blob/8109f6ca/cmake/cmake_celix/DockerPackaging.cmake
----------------------------------------------------------------------
diff --git a/cmake/cmake_celix/DockerPackaging.cmake b/cmake/cmake_celix/DockerPackaging.cmake
index ea5b8e0..55553c5 100644
--- a/cmake/cmake_celix/DockerPackaging.cmake
+++ b/cmake/cmake_celix/DockerPackaging.cmake
@@ -166,7 +166,7 @@ $<JOIN:$<TARGET_PROPERTY:${DOCKER_TARGET},DOCKER_EMBEDDED_PROPERTIES>,\\n\\
set_target_properties(${DOCKER_TARGET} PROPERTIES "DOCKER_EMBEDDED_PROPERTIES" "")
set_target_properties(${DOCKER_TARGET} PROPERTIES "DOCKER_DEPS" "")
- set(DOCKERFILE_STAGE1 ${CMAKE_BINARY_DIR}/celix/gen/${DOCKER_TARGET}/Dockerfile.in)
+ set(DOCKERFILE_STAGE1 ${CMAKE_BINARY_DIR}/celix/gen/docker/${DOCKER_TARGET}/Dockerfile.in)
set(DOCKERFILE "$<TARGET_PROPERTY:${DOCKER_TARGET},DOCKER_LOC>/Dockerfile")
file(GENERATE
@@ -187,7 +187,7 @@ $<JOIN:$<TARGET_PROPERTY:${DOCKER_TARGET},DOCKER_INSTRUCTIONS>,
#generate config.properties
set(DOCKER_PROPERTIES_FILE "${DOCKER_LOC}/${DOCKER_WORKDIR}/config.properties")
- set(STAGE1_PROPERTIES_FILE "${CMAKE_BINARY_DIR}/celix/gen/${DOCKER_TARGET}/docker-config-stage1.properties")
+ set(STAGE1_PROPERTIES_FILE "${CMAKE_BINARY_DIR}/celix/gen/docker/${DOCKER_TARGET}/docker-config-stage1.properties")
file(GENERATE
OUTPUT "${STAGE1_PROPERTIES_FILE}"
CONTENT "CELIX_AUTO_START_0=$<JOIN:$<TARGET_PROPERTY:${DOCKER_TARGET},DOCKER_BUNDLES_LEVEL_0>, >
@@ -270,7 +270,7 @@ function(celix_docker_bundles)
get_target_property(IMP ${BUNDLE} BUNDLE_IMPORTED)
if (IMP) #An imported bundle target -> handle target without DEPENDS
string(MAKE_C_IDENTIFIER ${BUNDLE} BUNDLE_ID) #Create id with no special chars (e.g. for target like Celix::shell)
- set(OUT "${CMAKE_BINARY_DIR}/celix/gen/${DOCKER_TARGET}/copy-bundle-for-target-${BUNDLE_ID}.timestamp")
+ set(OUT "${CMAKE_BINARY_DIR}/celix/gen/docker/${DOCKER_TARGET}/copy-bundle-for-target-${BUNDLE_ID}.timestamp")
set(DEST "${LOC}/${BUNDLES_DIR}/$<TARGET_PROPERTY:${BUNDLE},BUNDLE_FILENAME>")
add_custom_command(OUTPUT ${OUT}
COMMAND ${CMAKE_COMMAND} -E touch ${OUT}
@@ -286,7 +286,7 @@ function(celix_docker_bundles)
if(NOT HANDLED) #assuming (future) bundle target
string(MAKE_C_IDENTIFIER ${BUNDLE} BUNDLE_ID) #Create id with no special chars (e.g. for target like Celix::shell)
- set(OUT "${CMAKE_BINARY_DIR}/celix/gen/${DOCKER_TARGET}/copy-bundle-for-target-${BUNDLE_ID}.timestamp")
+ set(OUT "${CMAKE_BINARY_DIR}/celix/gen/docker/${DOCKER_TARGET}/copy-bundle-for-target-${BUNDLE_ID}.timestamp")
set(DEST "${LOC}/${BUNDLES_DIR}/$<TARGET_PROPERTY:${BUNDLE},BUNDLE_FILENAME>")
add_custom_command(OUTPUT ${OUT}
COMMAND ${CMAKE_COMMAND} -E touch ${OUT}
http://git-wip-us.apache.org/repos/asf/celix/blob/8109f6ca/documents/cmake_commands/readme.md
----------------------------------------------------------------------
diff --git a/documents/cmake_commands/readme.md b/documents/cmake_commands/readme.md
index 205e10d..4fc1b24 100644
--- a/documents/cmake_commands/readme.md
+++ b/documents/cmake_commands/readme.md
@@ -256,8 +256,7 @@ which in turn can be used to create very small Apache Celix docker images.
## add_celix_docker
Adds a docker target dir, containing a all the required executables,
-libraries and filesystem needed to run a Apache Celix framework in a docker container.
-Also includes the selected bundles.
+libraries, filesystem files and selected bundles needed to run a Apache Celix framework in a docker container.
The add_celix_docker target is a executable target and can be used to link libraries which are needed in the docker image.
@@ -350,4 +349,4 @@ celix_docker_instructions(<docker_target_name>
"instruction2"
...
)
-```
\ No newline at end of file
+```
http://git-wip-us.apache.org/repos/asf/celix/blob/8109f6ca/examples/celix-examples/civetweb/CMakeLists.txt
----------------------------------------------------------------------
diff --git a/examples/celix-examples/civetweb/CMakeLists.txt b/examples/celix-examples/civetweb/CMakeLists.txt
index 99926f9..5e469aa 100644
--- a/examples/celix-examples/civetweb/CMakeLists.txt
+++ b/examples/celix-examples/civetweb/CMakeLists.txt
@@ -27,11 +27,11 @@ add_celix_bundle(embedded_civetweb
)
target_link_libraries(embedded_civetweb PRIVATE Celix::shell_api)
celix_bundle_private_libs(embedded_civetweb civetweb_static)
-celix_bundle_dir(embedded_civetweb resources)
+celix_bundle_add_dir(embedded_civetweb resources)
add_celix_container(civetweb_example
BUNDLES
Celix::shell
Celix::shell_tui
embedded_civetweb
-)
\ No newline at end of file
+)
http://git-wip-us.apache.org/repos/asf/celix/blob/8109f6ca/examples/celix-examples/civetweb/resources/index.html
----------------------------------------------------------------------
diff --git a/examples/celix-examples/civetweb/resources/index.html b/examples/celix-examples/civetweb/resources/index.html
index ab46896..cf497cd 100644
--- a/examples/celix-examples/civetweb/resources/index.html
+++ b/examples/celix-examples/civetweb/resources/index.html
@@ -31,4 +31,5 @@
<textarea rows="50" cols="80" id="console_output"></textarea>
<script>docReady();</script>
</body>
-</html>
\ No newline at end of file
+</html>
+
http://git-wip-us.apache.org/repos/asf/celix/blob/8109f6ca/examples/celix-examples/civetweb/resources/script.js
----------------------------------------------------------------------
diff --git a/examples/celix-examples/civetweb/resources/script.js b/examples/celix-examples/civetweb/resources/script.js
index 588fbf6..10292cb 100644
--- a/examples/celix-examples/civetweb/resources/script.js
+++ b/examples/celix-examples/civetweb/resources/script.js
@@ -30,6 +30,7 @@ function docReady() {
document.getElementById("command_button").onclick = function() {
input = document.getElementById("command_input").value;
+ document.getElementById("command_input").value = "";
shellSocket.send(input);
};