Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
gitpod-io
GitHub Repository: gitpod-io/gitpod
Path: blob/main/components/ide/jetbrains/launcher/rebuild.sh
2501 views
1
#!/bin/bash
2
# Copyright (c) 2023 Gitpod GmbH. All rights reserved.
3
# Licensed under the GNU Affero General Public License (AGPL).
4
# See License.AGPL.txt in the project root for license information.
5
6
set -Eeuo pipefail
7
8
DIR="$(dirname "$(realpath "$0")")"
9
COMPONENT="$(basename "$DIR")"
10
cd "$DIR"
11
12
# build
13
go build .
14
echo "$COMPONENT built"
15
16
DIST_COMPONENT="jb-launcher"
17
mv "$COMPONENT" "$DIST_COMPONENT"
18
echo "rename $COMPONENT to $DIST_COMPONENT"
19
COMPONENT="$DIST_COMPONENT"
20
21
DEST="/ide-desktop"
22
sudo rm -rf "$DEST/$COMPONENT" && true
23
sudo mv ./"$COMPONENT" "$DEST"
24
echo "$COMPONENT in $DEST replaced"
25
26