From e282484c60d9d800be831f4c127eb9d8b0cac4fb Mon Sep 17 00:00:00 2001 From: ravinsp <33562092+ravinsp@users.noreply.github.com> Date: Fri, 12 Aug 2022 11:40:08 +0530 Subject: [PATCH] Wording changes. --- README.md | 8 ++++---- docker/Dockerfile | 4 ++-- .../code-templates/nodejs/starter-contract/package.json | 2 +- .../nodejs/starter-contract/src/_projname_.js | 2 +- .../nodejs/starter-contract/src/contract.js | 8 ++++---- docker/scripts/cluster.sh | 4 ++-- windows/hpdevkit.ps1 | 4 ++-- 7 files changed, 16 insertions(+), 16 deletions(-) diff --git a/README.md b/README.md index 86dc0a4..9daccbd 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,7 @@ -# Hot Pocket developer toolkit -Developer toolkit for Hot Pocket smart contract development. This toolkit makes use of Docker to provide a cross-platform development tools for developers. Using the toolkit, developers can spin-up local Hot Pocket clusters on their developer machines and test Hot Pocket smart contracts. +# HotPocket developer toolkit +Developer toolkit for HotPocket smart contract development. This toolkit makes use of Docker to provide a cross-platform development tools for developers. Using the toolkit, developers can spin-up local HotPocket clusters on their developer machines and test HotPocket smart contracts. -We use Docker containers to run Hot Pocket and smart contracts in a Linux environment. We also use Docker containers to distribute developer tools so developers can use the tools on any platform as long as they install Docker. +We use Docker containers to run HotPocket and smart contracts in a Linux environment. We also use Docker containers to distribute developer tools so developers can use the tools on any platform as long as they install Docker. image @@ -93,4 +93,4 @@ The executable can be distributed to be run as a CLI tool on developer machine. | HP_CLUSTER_SIZE | Number of nodes in the cluster. Applied with 'deploy' command. | `1` | | HP_DEFAULT_NODE | The node the 'deploy' command uses to display logs. | `1` | | HP_DEVKIT_IMAGE | Docker image to be used for devkit cluster management. | `evernodedev/hpdevkit` | -| HP_INSTANCE_IMAGE | Docker image to be used for Hot Pocket instances. | `evernodedev/hotpocket:latest-ubt.20.04-njs.16` | \ No newline at end of file +| HP_INSTANCE_IMAGE | Docker image to be used for HotPocket instances. | `evernodedev/hotpocket:latest-ubt.20.04-njs.16` | \ No newline at end of file diff --git a/docker/Dockerfile b/docker/Dockerfile index 4004d6a..a2fe473 100644 --- a/docker/Dockerfile +++ b/docker/Dockerfile @@ -1,4 +1,4 @@ -# This image contains scripts for creating Hot Pocket contract clusters +# This image contains scripts for creating HotPocket contract clusters # on the developer machine for local development testing. # docker build -t evernodedev/hpdevkit . # docker push evernodedev/hpdevkit @@ -16,7 +16,7 @@ RUN dpkg -x docker.deb docker-extracted RUN wget -O jq https://github.com/stedolan/jq/releases/download/jq-1.6/jq-linux64 RUN chmod +x jq -# Set permissions for hot pocket devkit scripts. +# Set permissions for hotpocket devkit scripts. COPY scripts /build/scripts RUN chmod -R +x /build/scripts/*.sh diff --git a/docker/code-templates/nodejs/starter-contract/package.json b/docker/code-templates/nodejs/starter-contract/package.json index 1c74d1a..9e5d370 100644 --- a/docker/code-templates/nodejs/starter-contract/package.json +++ b/docker/code-templates/nodejs/starter-contract/package.json @@ -7,7 +7,7 @@ "start": "npm run build && hpdevkit deploy dist" }, "dependencies": { - "hotpocket-nodejs-contract": "0.5.4", + "hotpocket-nodejs-contract": "0.5.6", "@vercel/ncc": "0.34.0" } } \ No newline at end of file diff --git a/docker/code-templates/nodejs/starter-contract/src/_projname_.js b/docker/code-templates/nodejs/starter-contract/src/_projname_.js index 2a302ae..c8c7656 100644 --- a/docker/code-templates/nodejs/starter-contract/src/_projname_.js +++ b/docker/code-templates/nodejs/starter-contract/src/_projname_.js @@ -44,7 +44,7 @@ export class _projname_ { } async setData(data) { - // Hot Pocket subjects data on-disk to consensus. + // HotPocket subjects data-on-disk to consensus. await fs.writeFile(dataFile, data); } diff --git a/docker/code-templates/nodejs/starter-contract/src/contract.js b/docker/code-templates/nodejs/starter-contract/src/contract.js index 67f8637..a9d429d 100644 --- a/docker/code-templates/nodejs/starter-contract/src/contract.js +++ b/docker/code-templates/nodejs/starter-contract/src/contract.js @@ -1,21 +1,21 @@ const HotPocket = require('hotpocket-nodejs-contract'); const { _projname_ } = require('./_projname_'); -// Hot Pocket smart contract is defined as a function which takes the Hot Pocket ExecutionContext as an argument. +// HotPocket smart contract is defined as a function which takes the HotPocket contract context as an argument. // This function gets invoked every consensus round and whenever a user sends a out-of-concensus read-request. async function contract(ctx) { // Create our application logic component. - // This pattern allows us to test the application logic independently of Hot Pocket. + // This pattern allows us to test the application logic independently of HotPocket. const app = new _projname_(); // Wire-up output emissions from the application before we pass user inputs to it. app.sendOutput = async (userPublicKey, output) => { - // In Hot Pocket, each user is represented by their Ed25519 public key. + // In HotPocket, each user is represented by their Ed25519 public key. const user = ctx.users.find(userPublicKey); await user.send(output) } - + // In 'readonly' mode, nothing our contract does will get persisted on the ledger. The benefit is // readonly messages gets processed much faster due to not being subjected to consensus. // We should only use readonly mode for returning/replying data for the requesting user. diff --git a/docker/scripts/cluster.sh b/docker/scripts/cluster.sh index a9768ca..c4737e6 100644 --- a/docker/scripts/cluster.sh +++ b/docker/scripts/cluster.sh @@ -75,7 +75,7 @@ function create_instance { let peer_port=22860+$node let user_port=8080+$node - # Create container for hot pocket instance. + # Create container for hotpocket instance. local container_name="${container_prefix}_$node" docker container create --name $container_name --privileged \ -p $user_port:$user_port --network $network --network-alias node$node \ @@ -116,7 +116,7 @@ function joinarr { echo $str } -# Update all instances hot pocket configs so they connect to each other as a cluster. +# Update all instances hotpocket configs so they connect to each other as a cluster. function bind_mesh { local instance_count=$(get_container_count) diff --git a/windows/hpdevkit.ps1 b/windows/hpdevkit.ps1 index a148968..0354b17 100644 --- a/windows/hpdevkit.ps1 +++ b/windows/hpdevkit.ps1 @@ -31,7 +31,7 @@ function DevKitContainer([string]$Mode, [string]$Name, [switch]$Detached, [switc } if ($MountSock) { # We mount the host docker socket into the container so we can use it to issue commands to the docker host. - # We use this ability to spin up other containers (Hot Pocket nodes) on the host. + # We use this ability to spin up other containers (HotPocket nodes) on the host. $Command += " --mount type=bind,src=/var/run/docker.sock,dst=/var/run/docker.sock" } if ($MountVolume) { @@ -142,7 +142,7 @@ Function CodeGenerator() { docker rm "$($CodegenContainerName)" 2>&1 | Out-Null } -Write-Host "Hot Pocket devkit launcher ($($Version))" +Write-Host "HotPocket devkit launcher ($($Version))" $Command = $args[0] $CommandError = "Invalid command. Expected: deploy | clean | start | stop | logs | gen"