Code Monkey home page Code Monkey logo

shrine's Introduction

Shrine is a TempleOS distribution full of sin.

Screenshot


Shrine aims to be 99% compatible with TempleOS programs, but also to improve OS in several ways:

  • Ease of use: Shrine ships with Lambda Shell, which feels a bit like a classic Unix command interpreter
  • Connectivity: TCP/IP stack & internet access out of the box
  • Software discovery: Shrine includes a package downloader

You can run Shrine in a virtual machine such as VirtualBox or QEMU, or on a machine compatible with standard TempleOS. Improvements in hardware support are planned and contributions are welcome.

Software included in Shrine:

  • Mfa (minimalist file access)
  • Lsh (Lambda Shell)
  • Pkg (package downloader)
  • Wget

Networking & host-VM communication

  • With a virtual AMD PCNet adapter (recommended)

    • configure your VM networking: Adapter Type: PCnet-PCI II (in QEMU: -netdev user,id=u1 -device pcnet,netdev=u1)
    • Attached to: NAT seems to be the most reliable setting, Bridged Mode also works somewhat
    • On boot, Shrine will automatically attempt to acquire an IP address. If you don't see a message about "Configuring network", the adapter was not detected.
  • Tunelled through serial port (Snail):

    • configure your VM: COM3 - TCP, server, 7777 (in VirtualBox, server = UNCHECK Connect to existing)
    • (make sure to disable networking for the VM, otherwise Native Stack will get precedence)
    • start the VM
    • run ./snail.py
    • you will now be able to access the Internet, try for example pkg-list
  • File access through Mfa:

    • configure your VM: COM1 - TCP, server, 7770
    • start /Apps/Mfa.HC.Z in the VM
    • on the host, use ./mfa.py to transfer commands and files
    • for example: ./mfa.py list /Apps/Mfa.HC.Z Mfa.HC

Networking and Mfa can be used simultaneously.

Package management functions

Note: In Lsh, use pkg-install xyz in place of PkgInstall("xyz") etc.

  • PkgList;

    List all packages available in the repository.

  • PkgInstall(U8* package_name);

    Download & install a specific package.

  • PkgInstallFromFile(U8* manifest_path);

    Manually install a downloaded package. Manifest must reference an existing .ISO.C path.

  • PkgMakeFromDir(U8* manifest_path, U8* src_dir);

    Build a package from directory contents. For an example manifest, check here. Manifest must reference a valid .ISO.C path which will be used as output!

  • PkgMakeFromFile(U8* manifest_path, U8* file_path);

    Build a package from a single file. See above for details.

See here for more information about how packages work.

Building from source

See here

shrine's People

Contributors

minexew avatar tos11 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

shrine's Issues

Failed to build with python3 ./make-dist.py

Following instructions i was able to make shrine.img but installing i get an error:

--- 15:08:31 -- user@comp: ~/Downloads/Shrine-master$ sudo python3 ./make-dist.py TOS_Distro.ISO Shrine ~/shrine.img

Traceback (most recent call last):
File "/home/user/Downloads/Shrine-master/inject_templeos.py", line 6, in
from isoc import RedSea
File "redseafs/isoc.py", line 22, in
from fuse import FUSE, FuseOSError, Operations, LoggingMixIn
File "/usr/local/lib/python3.5/dist-packages/fuse/init.py", line 3, in
from .defect_augment import DefectAugment
File "/usr/local/lib/python3.5/dist-packages/fuse/defect_augment.py", line 11, in
from gunpowder import BatchFilter
File "/usr/local/lib/python3.5/dist-packages/gunpowder/init.py", line 3, in
from . import nodes
File "/usr/local/lib/python3.5/dist-packages/gunpowder/nodes/init.py", line 3, in
from .add_affinities import AddAffinities
File "/usr/local/lib/python3.5/dist-packages/gunpowder/nodes/add_affinities.py", line 6, in
from gunpowder.ext import malis
File "/usr/local/lib/python3.5/dist-packages/gunpowder/ext/init.py", line 51, in
import augment
File "/usr/local/lib/python3.5/dist-packages/augment.py", line 181, in
def _surround(aux_fn, around=False, before=False, after=False):
File "/usr/local/lib/python3.5/dist-packages/augment.py", line 130, in decorator
allargs, fn_name = _get_args_and_name(fn)
File "/usr/local/lib/python3.5/dist-packages/augment.py", line 37, in _get_args_and_name
code = fn.func_code
AttributeError: 'function' object has no attribute 'func_code'
Traceback (most recent call last):
File "./make-dist.py", line 121, in
subprocess.check_call([INJECT_BIN, PATCHED_ISO, 'Once.HC.Z', SLAVE_HC_Z])
File "/usr/lib/python3.5/subprocess.py", line 581, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['/home/user/Downloads/Shrine-master/inject_templeos.py', 'TempleSlave.iso', 'Once.HC.Z', 'AutoOSInstall/SlaveOnce.HC.Z']' returned non-zero exit status 1

ImportError: cannot import name 'FUSE' from 'fuse' (/usr/lib/python3/dist-packages/fuse.py)

Tried to execute make after following these instructions.

Traceback (most recent call last):
  File "/home/arkadiy/Shrine/inject_templeos.py", line 6, in <module>
    from isoc import RedSea
  File "redseafs/isoc.py", line 22, in <module>
    from fuse import FUSE, FuseOSError, Operations, LoggingMixIn
ImportError: cannot import name 'FUSE' from 'fuse' (/usr/lib/python3/dist-packages/fuse.py)
Traceback (most recent call last):
  File "make-dist.py", line 121, in <module>
    subprocess.check_call([INJECT_BIN, PATCHED_ISO, 'Once.HC.Z', SLAVE_HC_Z])
  File "/usr/lib/python2.7/subprocess.py", line 190, in check_call
    raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['/home/arkadiy/Shrine/inject_templeos.py', 'TempleSlave.iso', 'Once.HC.Z', 'AutoOSInstall/SlaveOnce.HC.Z']' returned non-zero exit status 1
make: *** [Makefile:2: build] Error 1

Additional info

OS: Debian GNU/Linux buster/sid
Python: 2.7.16rc1 and 3.7.2+
QEMU: 1:3.1+dfsg-4

Failed to run make-dist.py

I was running the command ./make-dist.py TOS_Distro.ISO Shrine ~/shrine.img and expected the Shrine-HEAD.iso file to be outputted.

But as I run the command, this message appears:

Applied 2 patches, 669 bytes total
qemu-system-x86_64: -serial tcp::7770,server: info: QEMU waiting for connection on: disconnected:tcp::::7770,server
> ?

meanwhile, TempleOS boots in the background and it just stuck there for a few minutes before it errors out and shows this message:

qemu-system-x86_64: terminating on signal 15 from pid 6804 (<unknown process>)
Traceback (most recent call last):
  File "./make-dist.py", line 124, in <module>
    os.path.join(AUTO_INSTALL_PATH, 'install.script'), AUTO_INSTALL_TIMEOUT)
  File "./make-dist.py", line 106, in run_qemu_and_mfa
    wait_for_subprocess(mfa, timeout)
  File "./make-dist.py", line 83, in wait_for_subprocess
    raise Exception('Subprocess didn\'t finish in time')
Exception: Subprocess didn't finish in time

Additional info

OS: macOS 10.13.6
Python version: 2.7.10 and 3.7.0
QEMU version: 3.0.0

Screenshot of TempleOS wile running

GnuTools/SSH?

Can we add GnuTools and SSH packages? I'd do it myself but i'm retarded.

make-dist.py error

[chase@x220 Shrine-master]$ ./make-dist.py TOS_Distro.ISO Shrine ~/shrine.img 
Traceback (most recent call last):
  File "/home/chase/Downloads/Shrine-master/inject_templeos.py", line 6, in <module>
    from isoc import RedSea
  File "redseafs/isoc.py", line 22, in <module>
    from fuse import FUSE, FuseOSError, Operations, LoggingMixIn
ModuleNotFoundError: No module named 'fuse'
Traceback (most recent call last):
  File "./make-dist.py", line 121, in <module>
    subprocess.check_call([INJECT_BIN, PATCHED_ISO, 'Once.HC.Z', SLAVE_HC_Z])
  File "/usr/lib/python3.6/subprocess.py", line 291, in check_call
    raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['/home/chase/Downloads/Shrine-master/inject_templeos.py', 'TempleSlave.iso', 'Once.HC.Z', 'AutoOSInstall/SlaveOnce.HC.Z']' returned non-zero exit status 1.

24-bit color

24-bit color, at 8-bits per channel, enables users to access whatever colors they like and provides a richer visual experience. Today's hardware, and even yesterday's, can easily support it.

Convert Shrine from 4-bit palette to 24-bit direct color.

--
"A man who dares to waste one hour of time has not discovered the value of life."

In-place system upgrade

Definitely feasible and probably not even that difficult.

Might be enough to just unpack the latest ISO over filesystem, recompile kernel & reboot?

Future Vision

x86_64 is an arch of the past, and to keep things fun and interesting, we'll have to try something new.

RPi is pretty big right now, but implementing our own hardware support is unrealistic. We could either look at some of the other hobby OS kernel projects (though those are mostly x86-focused) or make use of Linux.

Other possibilities include going with something x86-based, but leveraging existing hardware support. TempleOS can't sit on top of Linux directly, because it handles registers and context switching differently. This also precludes Wine-like user-mode binary loaders (we certainly tried!).
Perhaps the compiler could abstract this even in existing codebase. TempleOS would then run as a single Linux process, managing its Tasks similar to how co-routines are implemented in C. Other kernel routines (disk, video, input) would be reimplemented by means of Linux syscalls. Either way, it would be no small undertaking.

At the very least, this implies we'll need a new compiler. JIT is a serious challenge, but also a big part of what makes this OS so unique, so it should be kept at all cost.

God says:
ahh, fuck it!

Files in distro ISO are not compressed

It's causing the following issues:

  • Autocomplete StandBy screen missing due to Doc/StandBy.DD missing the .Z

For the rest of the files, it seems to just be inefficient.

Implement TCP LISTEN mode

selaphiel (@tramplersheikhs) could certainly benefit from this.

This also implies flushing out some of the rougher edges in SnailNet/TCP.HC.

Should be also easy to do in tunnelled (snail.py) mode, though that's not a priority.

!

Rumor has it that the King is dead,

Restore BMP support

TempleOS update 877accc6598b79c75dc63bb9d5bc5e2ca446aab6 removes BMP support, replacing it with MV files and TOSZ functions that convert those into MP4.

We want BMP at the very least for Screenfetch, so we should either keep it in, or publish spin it off as a library.

IRC client

Hi, have you ever think about an irc client or an email client and other programs like that? This can be very useful for a very light OS like this! Let me know!

License

Where is the license?...
many users (including me) will refuse to use it if they don't know the terms and conditions in with the software is released

Thanks in advance

Restore ISO9660 support

Support for reading and writing ISO9660 has been removed from TOS recently.
There doesn't seem to be any good reason not to keep it in Shrine, therefore we should bring it back.

Color schemes

I noticed that you are changing the colors by changing the default color definitions (eg: redefining white or black).
How could I change the default foreground and background by specifying a color like FG=GREEN or BG=RED?
Terry's help files mentioned something about global variables but I couldn't figure out where they are stored or how to change them.

I managed to change the color of the status bar at the top (showing date and CPU load) by changing /Adam/WallPaper, but I would like to change the color of the terminal and the text editor.

Is Shrine OS based ( ;) ) on the latest Temple OS version?

Dear @minexew , first of all thank you very much for your wonderful Shrine OS project! Please tell, have you merged all the latest available updates of TempleOS (21-Nov-2017) into the Shrine OS ? By looking at your commits I see that you have updated your TempleOS directory to 21-Nov-2017, but it is unclear to me whether all the updates which happened after you forked TempleOS into Shrine, have also been merged into the Shrine sources

How do i solve this issue with snail.py?

Hello i am running snail.py in python 3.7 and i get this error:

Traceback (most recent call last):
  File "C:\Users\bruh\AppData\Local\Programs\Python\Python37\snail.py", line 12, in <module>
    sock.connect((TCP_IP, TCP_PORT))
ConnectionRefusedError: [WinError 10061] No connection could be made because the target machine actively refused it

How do i fix it? Config of vm:
image

Package server down

The package server's domain name expired and the pkg command no longer works.

shrine.systems not available

Hi! I just wanted to inform you that https://shrine.systems is not currently accessible. When visiting the website, Firefox gives me a SSL_ERROR_BAD_CERT_DOMAIN because the cert is registered to c84322.sgvps.net. Ignoring that message brings me to a page saying "This is the default server vhost" without anything else on the website. Perhaps something went wrong with the configuration?

Could Shrine fit on a 1.44MB or 2.88MB floppy?

Good day, @minexew and @tim241 . Please tell, could Shrine fit on a 1.44MB or 2.88MB floppy? Even today the floppies are still being used, for example - as virtual floppies inside the coreboot open source BIOS. Just imagine: your wonderful ShrineOS could be a part of someone's BIOS build! (for coreboot supported motherboard, maybe you have or could get one - see https://www.coreboot.org/Supported_Motherboards )

If you already have a coreboot-supported motherboard, or a real chance to get one, - wouldn't it be cool to be able to launch your own OS straight from the BIOS chip? ;) With one simple command its possible to add any floppy to coreboot BIOS build - and then you see it as a boot entry! Multiple floppies could be added this way (as long as you have enough space left inside the BIOS flash chip, luckily LZMA compression could be used for the stored floppies to reduce their occupied size)

So far I see 3.67 MB ISO image at your Shrine releases, but could it be somehow transformed into a floppy, maybe not 1.44MB but an 2.88MB one?

SSE support

...as seen in TempleOS-EE.
Required for Micropython with floats.

FUSE?

$ sudo pip install fuse
[...]
$ ./make-dist.py TOS_Distro.ISO Shrine ~/shrine.img
Traceback (most recent call last):
File "/home/jibanes/Downloads/Shrine-master/inject_templeos.py", line 6, in
from isoc import RedSea
File "redseafs/isoc.py", line 22, in
from fuse import FUSE, FuseOSError, Operations, LoggingMixIn
ImportError: cannot import name 'FUSE'
Traceback (most recent call last):
File "./make-dist.py", line 121, in
subprocess.check_call([INJECT_BIN, PATCHED_ISO, 'Once.HC.Z', SLAVE_HC_Z])
File "/usr/lib/python2.7/subprocess.py", line 540, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['/home/jibanes/Downloads/Shrine-master/inject_templeos.py', 'TempleSlave.iso', 'Once.HC.Z', 'AutoOSInstall/SlaveOnce.HC.Z']' returned non-zero exit status 1

Make ParseDhcpOffer work without a DNS address

Currently, if ParseDhcpOffer receives a DHCP offer that doesn't contain a DNS option, it fails. However, this makes testing Shrine within a VirtualBox host network (which doesn't have a DNS server) impossible, because the address resolution will consistently fail.

Because of that, ParseDhcpOffer should be made to accept DNS-less DHCP offers, as a DNS isn't required for normal operation of Shrine (from what I've seen at least).

VMs Shrine has been tested in?

I'm wondering which VMs the maintainers are recommending we try Shrine in... And what VMs they mostly test it in. KVM or VirtualBox?

Remove networking

It is said in the Temple OS charter that there shall be no networking, so that malware is not an issue:
http://www.templeos.org/Wb/Doc/Charter.html

God says...

naughty It_grieves_me ahh absetively_posilutely freak bank ingrate sex spunky What_are_you_doing_Dave shucks joking application a_flag_on_that_play stunning You_know downer I'm_not_sure run_away Icarus skills bad_ol_puddytat be_happy what_was_I_thinking dang_it game_over heathen so_he_sess it_figures IMHO hilarious how_do_I_put_this

Multiple software repositories?

What about adding ability to add custom repositories to package manager by entering their URLs to some file? It would be awesome.

Large amounts of TempleOS software links suddenly down.

It seems a large amount of the TempleOS software links on the internet such as all sheikhs.space have gone dead, like the game boy emulator and megaman games. I am trying to collect this and try to share it with others, such as the subreddit, IRC channel, and Archive.org collection, but so far I haven't had any luck.

Do you have any other TempleOS softwares, or know of working download links?

Thank you very much for your time,
Carrie

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.