Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
R
redoxer
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
mattmadeofpasta
redoxer
Commits
8f439486
Verified
Commit
8f439486
authored
5 years ago
by
Jeremy Soller
Browse files
Options
Downloads
Patches
Plain Diff
Add automatic shutdown and logging
parent
54a9e178
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
redoxer.sh
+32
-11
32 additions, 11 deletions
redoxer.sh
redoxer.toml
+1
-1
1 addition, 1 deletion
redoxer.toml
with
33 additions
and
12 deletions
redoxer.sh
+
32
−
11
View file @
8f439486
#!/usr/bin/env bash
set
-e
x
set
-e
if
[
!
-f
"
$1
"
]
then
...
...
@@ -11,25 +11,43 @@ fi
export
TARGET
=
x86_64-unknown-redox
sudo rm
-rf
build/redoxer build/redoxer.bin
rm
-f
build/redoxer-qemu.bin
rm
-f
build/redoxer.log
build/redoxer-qemu.bin
mkdir
-p
build/redoxer
if
!
which redox_installer
>
/dev/null
then
cargo
install
--git
https://gitlab.redox-os.org/redox-os/installer.git
cargo
\
install
\
--git
https://gitlab.redox-os.org/redox-os/installer.git
\
>>
build/redoxer.log
fi
sudo
"
$(
which redox_installer
)
"
-c
redoxer.toml build/redoxer
sudo
"
$(
which redox_installer
)
"
\
-c
redoxer.toml
\
build/redoxer
\
&>>build/redoxer.log
name
=
"
$(
basename
"
$1
"
)
"
sudo cp
"
$1
"
"build/redoxer/bin/
$name
"
echo
"stdio debug:"
|
sudo tee
build/redoxer/etc/init.d/10_redoxer
echo
"echo <redoxer>"
|
sudo tee
-a
build/redoxer/etc/init.d/10_redoxer
echo
"
$name
"
|
sudo tee
-a
build/redoxer/etc/init.d/10_redoxer
echo
"echo </redoxer>"
|
sudo tee
-a
build/redoxer/etc/init.d/10_redoxer
cat
>
build/redoxer.init
<<
EOF
stdio debug:
echo <redoxer>
$name
echo </redoxer>
shutdown
EOF
sudo cp
build/redoxer.init build/redoxer/etc/init.d/10_redoxer
if
!
which redoxfs
>
/dev/null
then
cargo
install
redoxfs
cargo
\
install
\
redoxfs
\
>>
build/redoxer.log
fi
sudo
"
$(
which redoxfs-ar
)
"
build/redoxer.bin build/redoxer build/redoxer/bootloader
sudo
"
$(
which redoxfs-ar
)
"
\
build/redoxer.bin
\
build/redoxer
\
build/redoxer/bootloader
\
>>
build/redoxer.log
cp
build/redoxer.bin build/redoxer-qemu.bin
qemu-system-x86_64
\
...
...
@@ -42,4 +60,7 @@ qemu-system-x86_64 \
-nographic
-vga
none
\
-enable-kvm
\
-cpu
host
\
-drive
file
=
build/redoxer-qemu.bin,format
=
raw
-drive
file
=
build/redoxer-qemu.bin,format
=
raw
\
>>
build/redoxer.log
sed
'/<redoxer>$/,/<\/redoxer>$/{//!b};d'
build/redoxer.log
This diff is collapsed.
Click to expand it.
redoxer.toml
+
1
−
1
View file @
8f439486
...
...
@@ -21,7 +21,7 @@ bootloader = {}
#cleye = {}
#cmatrix = {}
#contain = {}
#
coreutils = {}
coreutils
=
{}
#cpal = {}
#curl = {}
#dash = {}
...
...
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