Skip to content

Commit 36a8e24

Browse files
committed
Don't remove repos when installing Mynewt
1 parent 5d58c44 commit 36a8e24

File tree

2 files changed

+60
-58
lines changed

2 files changed

+60
-58
lines changed

scripts/install-mac.sh

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -162,15 +162,16 @@ fi
162162
which newt # Should show "/usr/local/bin/newt"
163163
newt version # Should show "Version: 1.7.0" or later. Should NOT show "...-dev".
164164

165-
echo "***** Installing mynewt..."
165+
# echo "***** Installing mynewt..."
166166

167-
# Remove the existing Mynewt OS in "repos"
168-
if [ -d repos ]; then
169-
rm -rf repos
170-
fi
167+
# # Remove the existing Mynewt OS in "repos"
168+
# if [ -d repos ]; then
169+
# rm -rf repos
170+
# fi
171171

172-
# Download Mynewt OS into the current project folder, under "repos" subfolder.
173-
newt install -v -f
172+
# # Download Mynewt OS into the current project folder, under "repos" subfolder.
173+
# newt install -v -f
174+
# echo ✅ ◾ ️Done! See README.md for Mynewt type conversion build fixes. Please restart Visual Studio Code to activate the extensions
174175

175176
set +x # Stop echoing all commands.
176-
echo ✅ ◾ ️Done! See README.md for Mynewt type conversion build fixes. Please restart Visual Studio Code to activate the extensions
177+
echo ✅ ◾ ️Done! Please restart Visual Studio Code to activate the extensions

scripts/install-windows.sh

Lines changed: 51 additions & 50 deletions
Original file line numberDiff line numberDiff line change
@@ -105,55 +105,56 @@ sudo apt install newt -y
105105
which newt # Should show "/usr/bin/newt"
106106
newt version # Should show "Version: 1.7.0" or later. Should NOT show "...-dev".
107107

108-
echo "***** Installing mynewt..."
109-
110-
# Remove the existing Mynewt OS in "repos"
111-
if [ -d repos ]; then
112-
rm -rf repos
113-
fi
114-
115-
# Download Mynewt OS into the current project folder, under "repos" subfolder.
116-
set +e # TODO: Remove this when newt install is fixed
117-
newt install -v -f # TODO: "git checkout" fails due to uncommitted files
118-
set -e # TODO: Remove this when newt install is fixed
119-
120-
# If you see "Error: Unknown subcommand: get-url"
121-
# then upgrade git as shown above.
122-
123-
echo "***** Reparing mynewt..."
124-
125-
# TODO: newt install fails due to uncommitted files. Need to check out manually.
126-
127-
# Check out core
128-
if [ -d repos/apache-mynewt-core ]; then
129-
pushd repos/apache-mynewt-core
130-
git checkout $mynewt_version -f
131-
popd
132-
fi
133-
# Check out nimble
134-
if [ -d repos/apache-mynewt-nimble ]; then
135-
pushd repos/apache-mynewt-nimble
136-
git checkout $nimble_version -f
137-
popd
138-
fi
139-
# Check out mcuboot
140-
if [ -d repos/mcuboot ]; then
141-
pushd repos/mcuboot
142-
git checkout $mcuboot_version -f
143-
popd
144-
fi
145-
146-
# If apache-mynewt-core is missing, then the installation failed.
147-
if [ ! -d repos/apache-mynewt-core ]; then
148-
echo "***** newt install failed"
149-
exit 1
150-
fi
151-
152-
# If apache-mynewt-nimble is missing, then the installation failed.
153-
if [ ! -d repos/apache-mynewt-nimble ]; then
154-
echo "***** newt install failed"
155-
exit 1
156-
fi
108+
# echo "***** Installing mynewt..."
109+
110+
# # Remove the existing Mynewt OS in "repos"
111+
# if [ -d repos ]; then
112+
# rm -rf repos
113+
# fi
114+
115+
# # Download Mynewt OS into the current project folder, under "repos" subfolder.
116+
# set +e # TODO: Remove this when newt install is fixed
117+
# newt install -v -f # TODO: "git checkout" fails due to uncommitted files
118+
# set -e # TODO: Remove this when newt install is fixed
119+
120+
# # If you see "Error: Unknown subcommand: get-url"
121+
# # then upgrade git as shown above.
122+
123+
# echo "***** Reparing mynewt..."
124+
125+
# # TODO: newt install fails due to uncommitted files. Need to check out manually.
126+
127+
# # Check out core
128+
# if [ -d repos/apache-mynewt-core ]; then
129+
# pushd repos/apache-mynewt-core
130+
# git checkout $mynewt_version -f
131+
# popd
132+
# fi
133+
# # Check out nimble
134+
# if [ -d repos/apache-mynewt-nimble ]; then
135+
# pushd repos/apache-mynewt-nimble
136+
# git checkout $nimble_version -f
137+
# popd
138+
# fi
139+
# # Check out mcuboot
140+
# if [ -d repos/mcuboot ]; then
141+
# pushd repos/mcuboot
142+
# git checkout $mcuboot_version -f
143+
# popd
144+
# fi
145+
146+
# # If apache-mynewt-core is missing, then the installation failed.
147+
# if [ ! -d repos/apache-mynewt-core ]; then
148+
# echo "***** newt install failed"
149+
# exit 1
150+
# fi
151+
152+
# # If apache-mynewt-nimble is missing, then the installation failed.
153+
# if [ ! -d repos/apache-mynewt-nimble ]; then
154+
# echo "***** newt install failed"
155+
# exit 1
156+
# fi
157+
# echo ✅ ◾ ️Done! See README.md for Mynewt type conversion build fixes. Please restart Visual Studio Code to activate the extensions
157158

158159
set +x # Stop echoing all commands.
159-
echo ✅ ◾ ️Done! See README.md for Mynewt type conversion build fixes. Please restart Visual Studio Code to activate the extensions
160+
echo ✅ ◾ ️Done! Please restart Visual Studio Code to activate the extensions

0 commit comments

Comments
 (0)