Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
ev3-toolbox-matlab
Manage
Activity
Members
Labels
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Deploy
Releases
Container registry
Model registry
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Code review analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
mindstorms
ev3-toolbox-matlab
Commits
d98a6a4d
Commit
d98a6a4d
authored
3 years ago
by
Dominik Mehlem
Browse files
Options
Downloads
Patches
Plain Diff
adapt rc.local.sh to work with mindstorms.startup directory
parent
88ae8a05
No related branches found
No related tags found
1 merge request
!14
adapt rc.local.sh to work with mindstorms.startup directory
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
tools/rc.local.sh
+3
-1
3 additions, 1 deletion
tools/rc.local.sh
with
3 additions
and
1 deletion
tools/rc.local.sh
+
3
−
1
View file @
d98a6a4d
...
@@ -65,6 +65,7 @@ done
...
@@ -65,6 +65,7 @@ done
# Mount all partitions read-only
# Mount all partitions read-only
echo
"Mounting all available partitions read-only ..."
echo
"Mounting all available partitions read-only ..."
chmod
o+rx /mnt
for
PART
in
/dev/disk/by-id/
*
;
do
for
PART
in
/dev/disk/by-id/
*
;
do
DEVICE
=
"
$(
readlink
-f
"
$PART
"
)
"
DEVICE
=
"
$(
readlink
-f
"
$PART
"
)
"
if
!
grep
-q
"^
$DEVICE
"
/etc/mtab
;
then
if
!
grep
-q
"^
$DEVICE
"
/etc/mtab
;
then
...
@@ -138,7 +139,7 @@ for SWP in /mnt/localfs/*/mindstorms.swp; do
...
@@ -138,7 +139,7 @@ for SWP in /mnt/localfs/*/mindstorms.swp; do
done
done
# Remove work directory if not mounted
# Remove work directory if not mounted
if
[
!
mountpoint
-q
/home/mindstorms/work
]
&&
[
!
PERSISTENT
]
;
then
if
!
mountpoint
-q
/home/mindstorms/work
&&
!
PERSISTENT
;
then
echo
"Removing work directory as no available mountpoint found."
echo
"Removing work directory as no available mountpoint found."
rm
-rf
/home/mindstorms/work
rm
-rf
/home/mindstorms/work
fi
fi
...
@@ -163,6 +164,7 @@ for PART in /mnt/localfs/*; do
...
@@ -163,6 +164,7 @@ for PART in /mnt/localfs/*; do
echo
"Unmounting
${
PART
}
."
echo
"Unmounting
${
PART
}
."
umount
"
$PART
"
2>/dev/null
umount
"
$PART
"
2>/dev/null
done
done
chmod
o-rx /mnt
# HACK: re-enable gnome's automount functionality.
# HACK: re-enable gnome's automount functionality.
echo
"Re-enabling gnome's automount functionality ..."
echo
"Re-enabling gnome's automount functionality ..."
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment