diff --git a/Cargo.lock b/Cargo.lock index 958195c..2b46058 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1532,7 +1532,7 @@ checksum = "c08d65885ee38876c4f86fa503fb49d7b507c2b62552df7c70b2fce627e06381" [[package]] name = "operator" -version = "0.6.1" +version = "0.6.2" dependencies = [ "actix-rt", "actix-web", diff --git a/Cargo.toml b/Cargo.toml index 2094e5c..ed15e7f 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "operator" -version = "0.6.1" +version = "0.6.2" authors = ["Matt Kantor "] description = "A web server for static and dynamic content" repository = "https://github.com/mkantor/operator" diff --git a/tests/snapshots/integration_tests__executables.snap b/tests/snapshots/integration_tests__executables.snap index 0d1be33..c0015ad 100644 --- a/tests/snapshots/integration_tests__executables.snap +++ b/tests/snapshots/integration_tests__executables.snap @@ -8,15 +8,14 @@ cat.txt.sh: "" count-cli-args.txt.sh: "0\n" error.txt.sh: "Unable to emit rendered content.\n\nCaused by:\n Process exited with code 1: boom!\n \n" get-pwd.txt.hbs: "this is pwd from subdirectory:\n$PROJECT_DIRECTORY/samples/executables/subdirectory\n" -get-render-data-with-custom-context.json.hbs: "{\"/\":{\"NO-SNAPSHOT-random\":\"/NO-SNAPSHOT-random\",\"NO-SNAPSHOT-system-info\":\"/NO-SNAPSHOT-system-info\",\"cat\":\"/cat\",\"count-cli-args\":\"/count-cli-args\",\"error\":\"/error\",\"get-pwd\":\"/get-pwd\",\"get-render-data\":\"/get-render-data\",\"get-render-data-with-custom-context\":\"/get-render-data-with-custom-context\",\"get-render-data-with-hash-params\":\"/get-render-data-with-hash-params\",\"ls\":\"/ls\",\"output-and-error\":\"/output-and-error\",\"pwd\":\"/pwd\",\"render-data\":\"/render-data\",\"slow\":\"/slow\",\"slow-error\":\"/slow-error\",\"slow-template\":\"/slow-template\",\"subdirectory/\":{\"pwd\":\"/subdirectory/pwd\"}},\"error-code\":null,\"pwd\":\"/subdirectory/pwd\",\"request\":{\"query-parameters\":{},\"request-headers\":{},\"route\":\"/get-render-data-with-custom-context\"},\"server-info\":{\"operator-path\":\"$PROJECT_DIRECTORY/target/$PROFILE/operator\",\"socket-address\":\"$SOCKET_ADDRESS\",\"version\":\"0.6.1\"},\"target-media-type\":\"application/json\"}\n" -get-render-data-with-hash-params.json.hbs: "{\"/\":{\"NO-SNAPSHOT-random\":\"/NO-SNAPSHOT-random\",\"NO-SNAPSHOT-system-info\":\"/NO-SNAPSHOT-system-info\",\"cat\":\"/cat\",\"count-cli-args\":\"/count-cli-args\",\"error\":\"/error\",\"get-pwd\":\"/get-pwd\",\"get-render-data\":\"/get-render-data\",\"get-render-data-with-custom-context\":\"/get-render-data-with-custom-context\",\"get-render-data-with-hash-params\":\"/get-render-data-with-hash-params\",\"ls\":\"/ls\",\"output-and-error\":\"/output-and-error\",\"pwd\":\"/pwd\",\"render-data\":\"/render-data\",\"slow\":\"/slow\",\"slow-error\":\"/slow-error\",\"slow-template\":\"/slow-template\",\"subdirectory/\":{\"pwd\":\"/subdirectory/pwd\"}},\"custom-param-1\":\"wowie\",\"custom-param-2\":42,\"error-code\":\"overridden\",\"request\":{\"query-parameters\":{},\"request-headers\":{},\"route\":\"/get-render-data-with-hash-params\"},\"server-info\":{\"operator-path\":\"$PROJECT_DIRECTORY/target/$PROFILE/operator\",\"socket-address\":\"$SOCKET_ADDRESS\",\"version\":\"0.6.1\"},\"target-media-type\":\"application/json\"}\n" -get-render-data.json.hbs: "{\"/\":{\"NO-SNAPSHOT-random\":\"/NO-SNAPSHOT-random\",\"NO-SNAPSHOT-system-info\":\"/NO-SNAPSHOT-system-info\",\"cat\":\"/cat\",\"count-cli-args\":\"/count-cli-args\",\"error\":\"/error\",\"get-pwd\":\"/get-pwd\",\"get-render-data\":\"/get-render-data\",\"get-render-data-with-custom-context\":\"/get-render-data-with-custom-context\",\"get-render-data-with-hash-params\":\"/get-render-data-with-hash-params\",\"ls\":\"/ls\",\"output-and-error\":\"/output-and-error\",\"pwd\":\"/pwd\",\"render-data\":\"/render-data\",\"slow\":\"/slow\",\"slow-error\":\"/slow-error\",\"slow-template\":\"/slow-template\",\"subdirectory/\":{\"pwd\":\"/subdirectory/pwd\"}},\"error-code\":null,\"request\":{\"query-parameters\":{},\"request-headers\":{},\"route\":\"/get-render-data\"},\"server-info\":{\"operator-path\":\"$PROJECT_DIRECTORY/target/$PROFILE/operator\",\"socket-address\":\"$SOCKET_ADDRESS\",\"version\":\"0.6.1\"},\"target-media-type\":\"application/json\"}\n" +get-render-data-with-custom-context.json.hbs: "{\"/\":{\"NO-SNAPSHOT-random\":\"/NO-SNAPSHOT-random\",\"NO-SNAPSHOT-system-info\":\"/NO-SNAPSHOT-system-info\",\"cat\":\"/cat\",\"count-cli-args\":\"/count-cli-args\",\"error\":\"/error\",\"get-pwd\":\"/get-pwd\",\"get-render-data\":\"/get-render-data\",\"get-render-data-with-custom-context\":\"/get-render-data-with-custom-context\",\"get-render-data-with-hash-params\":\"/get-render-data-with-hash-params\",\"ls\":\"/ls\",\"output-and-error\":\"/output-and-error\",\"pwd\":\"/pwd\",\"render-data\":\"/render-data\",\"slow\":\"/slow\",\"slow-error\":\"/slow-error\",\"slow-template\":\"/slow-template\",\"subdirectory/\":{\"pwd\":\"/subdirectory/pwd\"}},\"error-code\":null,\"pwd\":\"/subdirectory/pwd\",\"request\":{\"query-parameters\":{},\"request-headers\":{},\"route\":\"/get-render-data-with-custom-context\"},\"server-info\":{\"operator-path\":\"$PROJECT_DIRECTORY/target/$PROFILE/operator\",\"socket-address\":\"$SOCKET_ADDRESS\",\"version\":\"0.6.2\"},\"target-media-type\":\"application/json\"}\n" +get-render-data-with-hash-params.json.hbs: "{\"/\":{\"NO-SNAPSHOT-random\":\"/NO-SNAPSHOT-random\",\"NO-SNAPSHOT-system-info\":\"/NO-SNAPSHOT-system-info\",\"cat\":\"/cat\",\"count-cli-args\":\"/count-cli-args\",\"error\":\"/error\",\"get-pwd\":\"/get-pwd\",\"get-render-data\":\"/get-render-data\",\"get-render-data-with-custom-context\":\"/get-render-data-with-custom-context\",\"get-render-data-with-hash-params\":\"/get-render-data-with-hash-params\",\"ls\":\"/ls\",\"output-and-error\":\"/output-and-error\",\"pwd\":\"/pwd\",\"render-data\":\"/render-data\",\"slow\":\"/slow\",\"slow-error\":\"/slow-error\",\"slow-template\":\"/slow-template\",\"subdirectory/\":{\"pwd\":\"/subdirectory/pwd\"}},\"custom-param-1\":\"wowie\",\"custom-param-2\":42,\"error-code\":\"overridden\",\"request\":{\"query-parameters\":{},\"request-headers\":{},\"route\":\"/get-render-data-with-hash-params\"},\"server-info\":{\"operator-path\":\"$PROJECT_DIRECTORY/target/$PROFILE/operator\",\"socket-address\":\"$SOCKET_ADDRESS\",\"version\":\"0.6.2\"},\"target-media-type\":\"application/json\"}\n" +get-render-data.json.hbs: "{\"/\":{\"NO-SNAPSHOT-random\":\"/NO-SNAPSHOT-random\",\"NO-SNAPSHOT-system-info\":\"/NO-SNAPSHOT-system-info\",\"cat\":\"/cat\",\"count-cli-args\":\"/count-cli-args\",\"error\":\"/error\",\"get-pwd\":\"/get-pwd\",\"get-render-data\":\"/get-render-data\",\"get-render-data-with-custom-context\":\"/get-render-data-with-custom-context\",\"get-render-data-with-hash-params\":\"/get-render-data-with-hash-params\",\"ls\":\"/ls\",\"output-and-error\":\"/output-and-error\",\"pwd\":\"/pwd\",\"render-data\":\"/render-data\",\"slow\":\"/slow\",\"slow-error\":\"/slow-error\",\"slow-template\":\"/slow-template\",\"subdirectory/\":{\"pwd\":\"/subdirectory/pwd\"}},\"error-code\":null,\"request\":{\"query-parameters\":{},\"request-headers\":{},\"route\":\"/get-render-data\"},\"server-info\":{\"operator-path\":\"$PROJECT_DIRECTORY/target/$PROFILE/operator\",\"socket-address\":\"$SOCKET_ADDRESS\",\"version\":\"0.6.2\"},\"target-media-type\":\"application/json\"}\n" ls.txt.sh: "NO-SNAPSHOT-random.bin.sh\nNO-SNAPSHOT-system-info.html.sh\ncat.txt.sh\ncount-cli-args.txt.sh\nerror.txt.sh\nget-pwd.txt.hbs\nget-render-data-with-custom-context.json.hbs\nget-render-data-with-hash-params.json.hbs\nget-render-data.json.hbs\nls.txt.sh\noutput-and-error.txt.sh\npwd.txt.sh\nrender-data.json.sh\nslow-error.txt.sh\nslow-template.txt.hbs\nslow.txt.sh\nsubdirectory\n" output-and-error.txt.sh: "Unable to emit rendered content.\n\nCaused by:\n Process exited with code 1\n" pwd.txt.sh: "$PROJECT_DIRECTORY/samples/executables\n" -render-data.json.sh: "{\"/\":{\"NO-SNAPSHOT-random\":\"/NO-SNAPSHOT-random\",\"NO-SNAPSHOT-system-info\":\"/NO-SNAPSHOT-system-info\",\"cat\":\"/cat\",\"count-cli-args\":\"/count-cli-args\",\"error\":\"/error\",\"get-pwd\":\"/get-pwd\",\"get-render-data\":\"/get-render-data\",\"get-render-data-with-custom-context\":\"/get-render-data-with-custom-context\",\"get-render-data-with-hash-params\":\"/get-render-data-with-hash-params\",\"ls\":\"/ls\",\"output-and-error\":\"/output-and-error\",\"pwd\":\"/pwd\",\"render-data\":\"/render-data\",\"slow\":\"/slow\",\"slow-error\":\"/slow-error\",\"slow-template\":\"/slow-template\",\"subdirectory/\":{\"pwd\":\"/subdirectory/pwd\"}},\"server-info\":{\"version\":\"0.6.1\",\"operator-path\":\"$PROJECT_DIRECTORY/target/$PROFILE/operator\",\"socket-address\":\"$SOCKET_ADDRESS\"},\"target-media-type\":\"application/json\",\"request\":{\"route\":\"/render-data\",\"query-parameters\":{},\"request-headers\":{}},\"error-code\":null}\n" +render-data.json.sh: "{\"/\":{\"NO-SNAPSHOT-random\":\"/NO-SNAPSHOT-random\",\"NO-SNAPSHOT-system-info\":\"/NO-SNAPSHOT-system-info\",\"cat\":\"/cat\",\"count-cli-args\":\"/count-cli-args\",\"error\":\"/error\",\"get-pwd\":\"/get-pwd\",\"get-render-data\":\"/get-render-data\",\"get-render-data-with-custom-context\":\"/get-render-data-with-custom-context\",\"get-render-data-with-hash-params\":\"/get-render-data-with-hash-params\",\"ls\":\"/ls\",\"output-and-error\":\"/output-and-error\",\"pwd\":\"/pwd\",\"render-data\":\"/render-data\",\"slow\":\"/slow\",\"slow-error\":\"/slow-error\",\"slow-template\":\"/slow-template\",\"subdirectory/\":{\"pwd\":\"/subdirectory/pwd\"}},\"server-info\":{\"version\":\"0.6.2\",\"operator-path\":\"$PROJECT_DIRECTORY/target/$PROFILE/operator\",\"socket-address\":\"$SOCKET_ADDRESS\"},\"target-media-type\":\"application/json\",\"request\":{\"route\":\"/render-data\",\"query-parameters\":{},\"request-headers\":{}},\"error-code\":null}\n" slow-error.txt.sh: "Unable to emit rendered content.\n\nCaused by:\n Process exited with code 1: Boom!\n \n" slow-template.txt.hbs: "🔴 Ready…\n🟡 Set…\n🟢 Go!\n🏁 Finished!\n" slow.txt.sh: "🔴 Ready…\n🟡 Set…\n🟢 Go!\n" subdirectory/pwd.txt.sh: "$PROJECT_DIRECTORY/samples/executables/subdirectory\n" -