diff --git a/connect.sh b/connect.sh new file mode 100644 index 0000000..6dbda32 --- /dev/null +++ b/connect.sh @@ -0,0 +1,9 @@ +url="https://api.powerbi.com/beta/72f988bf-86f1-41af-91ab-2d7cd011db47/datasets/db49b474-9a6a-40c9-b5f9-be94dc8228a8/rows?key=tJvZgjg52aeMzUf%2FzPsbWZa1K%2BVrDKem%2FCneSY5FbV9GOW5%2B8ctaNwHAiYMaxbbfv%2FwFCTJUUTstqBRNo%2BUlZA%3D%3D" +build_time=`date +%Y-%m-%dT%H:%M:%S` +computer_name=`hostname` +curl --include --request POST --header "Content-Type: application/json" --data-binary "[{ +\"Build time\" :\"$build_time\", +\"Computer name\" :\"$computer_name\", +\"Project name\" :\"$1\", +\"score\" :1 +}]" $url diff --git a/core/CMakeLists.txt b/core/CMakeLists.txt index d2dc6dd..950513d 100644 --- a/core/CMakeLists.txt +++ b/core/CMakeLists.txt @@ -20,3 +20,7 @@ TARGET_LINK_LIBRARIES(core pthread dl sample) + +execute_process( + COMMAND ${CMAKE_SOURCE_DIR}/connect.sh Core +) diff --git a/gui/CMakeLists.txt b/gui/CMakeLists.txt index b4272c9..486d2ef 100644 --- a/gui/CMakeLists.txt +++ b/gui/CMakeLists.txt @@ -12,3 +12,7 @@ FILE(GLOB SRC src/*.cpp) ADD_LIBRARY(gui ${SRC}) TARGET_LINK_LIBRARIES(gui core sample) + +execute_process( + COMMAND ${CMAKE_SOURCE_DIR}/connect.sh Gui +)