main: work in progress [might break]
This commit is contained in:
parent
52f7766bca
commit
a3a9fae294
|
@ -11,7 +11,7 @@ source /etc/profile.xrsh
|
|||
source /etc/profile.sh
|
||||
|
||||
# source js functions
|
||||
./.profile.js | grep -v undefined
|
||||
test -f /etc/profile.js && chmod +x /etc/profile.js && /etc/profile.js | grep -v undefined
|
||||
|
||||
## forward not-found commands to javascript (via jsh)
|
||||
command_not_found_handle(){
|
||||
|
@ -34,18 +34,26 @@ help(){
|
|||
echo 'include file into page' "type 'require <url.js|css>'"
|
||||
echo 'create AFRAME a-entity' "type 'a_entity <componentname> [...]"
|
||||
echo ''
|
||||
echo 'type "man -l /root/manual.md" to read the full manual"'
|
||||
echo 'type "man xrsh" to read the full manual'
|
||||
ONBOARDING=1
|
||||
}
|
||||
|
||||
export TERM=xterm-256color
|
||||
export PS1="\n\[\033[38;5;57m\]x\[\033[38;5;93m\]r\[\033[38;5;129m\]s\[\033[38;5;165m\]h \[\033[38;5;201m\]# \[\033[0m\]"
|
||||
export PS1="\[\033[38;5;165m\]> \[\033[0m\]"
|
||||
|
||||
# interactive login
|
||||
[[ -t 0 ]] && {
|
||||
cat /etc/motd
|
||||
test -n "$STY" || {
|
||||
screen -R -T screen-256color -c /root/.screenrc
|
||||
resize # call twice
|
||||
resize # otherwise COLUMNS/ROWS is 0
|
||||
# add URL-hash as extra screen session
|
||||
test -z "$HASH" || {
|
||||
grep 'screen -t #' /root/.screenrc || {
|
||||
echo "screen -t xrsh+URL 2 /bin/sh -c '${HASH}; sh'" | sed "s/'#/'/g" >> /root/.screenrc
|
||||
}
|
||||
}
|
||||
screen -Aa -R -T screen-256color -c /root/.screenrc
|
||||
}
|
||||
test -n "$STY" && cat /etc/motd
|
||||
}
|
||||
|
||||
|
|
|
@ -46,6 +46,12 @@ require(){
|
|||
})()'
|
||||
}
|
||||
|
||||
man(){
|
||||
test "$1" = xrsh && {
|
||||
cat /root/manual.md | less
|
||||
}
|
||||
}
|
||||
|
||||
a_entity(){
|
||||
code="let el = document.createElement('a-entity')"
|
||||
for i in "$@"; do
|
||||
|
|
|
@ -18,7 +18,8 @@ test -d /dev/browser || {
|
|||
echo 1 > /mnt/console.tty
|
||||
ln -s /mnt/console.tty /dev/browser/tty
|
||||
ln -fs /mnt/js /dev/browser/js
|
||||
touch /dev/browser/console
|
||||
ln -fs /mnt/console /dev/browser/console
|
||||
touch /mnt/console
|
||||
touch /dev/browser/index.html
|
||||
}
|
||||
|
||||
|
|
|
@ -34,8 +34,4 @@ defbce on # use current bg color for erased chars
|
|||
|
||||
# setup windows
|
||||
screen -t jsconsole 0 tail -f /dev/browser/console
|
||||
screen -t jsh 1 jsh
|
||||
screen -t xrsh 2
|
||||
|
||||
##If you want it to start with a particular window active, you can add a line like the following:
|
||||
#select 1
|
||||
screen -t xrsh 1
|
||||
|
|
|
@ -0,0 +1,2 @@
|
|||
#!/bin/sh
|
||||
|
|
@ -14,6 +14,7 @@ BR2_PACKAGE_ZIP=y
|
|||
BR2_PACKAGE_LUA=y
|
||||
BR2_PACKAGE_MICROPYTHON=y
|
||||
BR2_PACKAGE_SCREEN=y
|
||||
BR2_PACKAGE_MG=y
|
||||
BR2_PACKAGE_NANO=y
|
||||
BR2_TARGET_ROOTFS_INITRAMFS=y
|
||||
BR2_TARGET_ROOTFS_ISO9660=y
|
||||
|
|
Binary file not shown.
Loading…
Reference in New Issue