mirror of
https://github.com/redhat-developer/odo.git
synced 2025-10-19 03:06:19 +03:00
* #4062 Update installing odo on Windows section to fix filename and add additional steps and information required * #4062 updated to make it generic, got rid of go/bin references * Incorporated feedback from dharmit * #4062 made changes to replace tar.gz for .zip for windows installer * #4062 incorporated feedback from Dharmit * #4062 Fixed a couple of typos to addres dharmit feedback * 4062 fix mising dot in .exe * 4062 fix if sattement * 4062 fix syntax error * 4062 fix syntax error * 4062 fix syntax error * 4062 fix syntax error * 4062 fix syntax error * Fixed statements for when suffix is .exe * Fixed if syntax * changed syntax * Fixed syntax * fixed zip command syntax * Removed unnecessary comments and updtaed redistributable filename to add .exe before .zip
This commit is contained in:
@@ -46,28 +46,28 @@ The following section describes how to install `odo` on different platforms via
|
||||
|
||||
=== Binary installation
|
||||
|
||||
. Download the latest link:https://mirror.openshift.com/pub/openshift-v4/clients/odo/latest/odo-windows-amd64.exe[`odo.exe`] file.
|
||||
. Add the location of your `odo.exe` to your `GOPATH/bin` directory.
|
||||
. Download the latest link:https://mirror.openshift.com/pub/openshift-v4/clients/odo/latest/odo-windows-amd64.exe[`odo-windows-amd64.exe`] file.
|
||||
. Rename the downloaded file to `odo.exe` and move it to a folder of your choice, for example `C:\odo`
|
||||
. Add the location of your `odo.exe` to your `%PATH%`.
|
||||
|
||||
=== Setting the `PATH` variable for Windows 10
|
||||
|
||||
Edit `Environment Variables` using search:
|
||||
The following example demonstrates how to set up a path variable. Your binary can be located in any location, but this example uses C:\odo as the location.
|
||||
|
||||
. Click *Search* and type `env` or `environment`.
|
||||
. Select *Edit environment variables for your account*.
|
||||
. Select *Path* from the *Variable* section and click *Edit*.
|
||||
. Click *New* and type `C:\go-bin` into the field or click *Browse* and select the directory, and click *OK*.
|
||||
. Click *New* and type `C:\odo` into the field or click *Browse* and select the directory, and click *OK*.
|
||||
|
||||
=== Setting the `PATH` variable for Windows 7/8
|
||||
|
||||
The following example demonstrates how to set up a path variable. Your binaries can be located in any location, but this example uses C:\go-bin as the location.
|
||||
|
||||
. Create a folder at `C:\go-bin`.
|
||||
. Right click *Start* and click *Control Panel*.
|
||||
. Select *System and Security* and then click *System*.
|
||||
. From the menu on the left, select the *Advanced systems settings* and click the *Environment Variables* button at the bottom.
|
||||
. Select *Path* from the *Variable* section and click *Edit*.
|
||||
. Click *New* and type `C:\go-bin` into the field or click *Browse* and select the directory, and click *OK*.
|
||||
. Click *Start* and in the `Search` box types `Advance System Settings`.
|
||||
. Select *Advanced systems settings* and click the *Environment Variables* button at the bottom.
|
||||
. Select the *Path* variable from the *System variable* section and click *Edit*.
|
||||
. Scroll to the end of the *Variable Value* and add `;C:\odo` and click *OK*.
|
||||
. Click *OK* to close the *Environment Variable* dialog.
|
||||
. Click *OK* to close the *Systems Properties* dialog.
|
||||
|
||||
= Installing odo in Visual Studio Code (VSCode)
|
||||
|
||||
|
||||
@@ -61,6 +61,7 @@ install -p -m 755 dist/release/odo-linux-s390x %{buildroot}%{_datadir}/%{name}-r
|
||||
install -p -m 755 dist/release/odo-darwin-amd64 %{buildroot}%{_datadir}/%{name}-redistributable/odo-darwin-amd64
|
||||
install -p -m 755 dist/release/odo-windows-amd64.exe %{buildroot}%{_datadir}/%{name}-redistributable/odo-windows-amd64.exe
|
||||
cp -avrf dist/release/odo*.tar.gz %{buildroot}%{_datadir}/%{name}-redistributable
|
||||
cp -avrf dist/release/odo*.zip %{buildroot}%{_datadir}/%{name}-redistributable
|
||||
cp -avrf dist/release/SHA256_SUM %{buildroot}%{_datadir}/%{name}-redistributable
|
||||
cp -avrf dist/release/VERSION %{buildroot}%{_datadir}/%{name}-redistributable
|
||||
|
||||
@@ -92,6 +93,6 @@ Obsoletes: %{package_name}-redistributable <= %{odo_version}
|
||||
%{_datadir}/%{name}-redistributable/odo-darwin-amd64
|
||||
%{_datadir}/%{name}-redistributable/odo-darwin-amd64.tar.gz
|
||||
%{_datadir}/%{name}-redistributable/odo-windows-amd64.exe
|
||||
%{_datadir}/%{name}-redistributable/odo-windows-amd64.exe.tar.gz
|
||||
%{_datadir}/%{name}-redistributable/odo-windows-amd64.exe.zip
|
||||
%{_datadir}/%{name}-redistributable/SHA256_SUM
|
||||
%{_datadir}/%{name}-redistributable/VERSION
|
||||
|
||||
@@ -32,8 +32,13 @@ for arch in `ls -1 $BIN_DIR/`;do
|
||||
target_file=$RELEASE_DIR/odo-$arch$suffix
|
||||
|
||||
# Create a tar.gz of the binary
|
||||
echo "gzipping binary $source_file as $target_file"
|
||||
if [[ $suffix == .exe ]]; then
|
||||
echo "zipping binary $source_file as $target_file.zip"
|
||||
zip -9 -y -r -q $target_file.zip $source_dir/$source_filename
|
||||
else
|
||||
echo "gzipping binary $source_file as $target_file.tar.gz"
|
||||
tar -czvf $target_file.tar.gz --directory=$source_dir $source_filename
|
||||
fi
|
||||
|
||||
# Move binaries to the release directory as well
|
||||
echo "copying binary $source_file to release directory"
|
||||
|
||||
Reference in New Issue
Block a user