Giter Club home page Giter Club logo

mimixbox's Introduction

Build UnitTest IntegrationTest GitHub GitHub all releases Lines of code Support me on Patreon

[日本語]

MimixBox - mimic BusyBox on Linux

MimixBox has many Unix commands in the single binary like BusyBox. However, MimixBox aim for the different uses from BusyBox. Specifically, it is supposed to be used in the desktop environment, not the embedded environment.
Also, the MimixBox project maintainer plan to have a wide range of built-in commands (applets) from basic command provided by Coreutils and others to experimental commands.

Installation.

The source code and binaries are distributed on the Release Page in ZIP format and tar.gz format. Choose the binary that suits your OS and CPU architecture. For example, in the case of Linux (amd64), you can install the MimixBox and documents on your system with the following command:

$ tar xf mimixbox-0.30.0-linux-amd64.tar.gz
$ cd mimixbox-0.30.0-linux-amd64
$ sudo ./installer.sh

If you have a Golang development environment, you can also install it by the following method. This method does not install the documentation.

$ go install github.com/nao1215/mimixbox/cmd/mimixbox@latest
$ sudo mimixbox --install /usr/local/bin

Development

Tools & Libraries

The table below shows the tools used when developing the commands in the MimixBox project.

Tool description
go-licenses Used for license management of dependent libraries
pandoc Convert markdown files to manpages
make Used for build, test, release, etc
gzip Used for compress man pages
curl Used for install ShellSpec
install Used for install MimixBox binary and document in the system
docker Used for testing Mimixbox inside Docker
debootstrap Used for testing Mimixbox inside jail envrioment
shellspec Used for integration test
libpam0g-dev(pam-devel) PAM (Pluggable Authentication Modules) library

If you use Debian-based distribution (e.g. Debian/Ubuntu/Kali Linux/Raspberry Pi OS), You can install tools with the following command.

$ sudo apt install build-essential curl git pandoc gzip docker.io debootstrap libpam0g-dev
$ go install github.com/google/go-licenses@latest
$ curl -fsSL https://git.io/shellspec | sh -s -- --yes

How to build

$ git clone https://github.com/nao1215/mimixbox.git
$ cd mimixbox
$ make build

How to create docker environment

$ make docker

※ Once the Docker image build is complete, you'll be inside the container.
$ 

How to create jail environment

$ sudo apt install debootstrap    ※ If you have not installed debootstrap in Ubuntu.
$ make build                      ※ Build mimixbox binary
$ sudo make jail                  ※ Create jail environment at /tmp/mimixbox/jail

$ sudo chroot /tmp/mimixbox/jail /bin/bash   ※ Dive to jail
# mimixbox --full-install /usr/local/bin     ※ Install MimixBox's command in jail

Roadmap

  • Step1. Implements many common Unix commands (〜Version 0.x.x).
  • Step2. Increase the options for each commands (〜Version 1.x.x).
  • Step3. Change the command to modern specifications(〜Version 2.x.x)

Now, MimixBox has not implemented enough commands (currently supported command list is here). Therefore, as a project, we will increase the number of commands and aim for a state where dog fooding can be done with the highest priority.

Then increase the command options to the same level as Coreutils and other packages. Note that MimixBox does not aim to create commands equivalent to Coreutils. However, we think it's better to have the options that Linux users expect.

Finally, it's the phase that makes the Mimix Box unique. Extend commands to high functionality, like bat and lsd, which are reimplementations of cat and ls.

Original commands in MimixBox

MimixBox has its own commands that don't exist in packages like Coreutils.

Command (Applet) Name Description
fakemovie Adds a video playback button to the image
ghrdc GitHub Relase Download Counter
path Manipulate filename path
sddf Search & Delete Dupulicated File
serial Rename the file to the name with a serial number

Contributing

First off, thanks for taking the time to contribute! ❤️ See CONTRIBUTING.md for more information. Contributions are not only related to development. For example, GitHub Star motivates me to develop! Star History Chart

Contact

If you would like to send comments such as "find a bug" or "request for additional features" to the developer, please use one of the following contacts. We are also looking forward to sponsorship.

LICENSE

The MimixBox project is licensed under the terms of the MIT license and Apache License 2.0.
See LICENSE and NOTICE

mimixbox's People

Contributors

dependabot[bot] avatar k-avy avatar nao1215 avatar polynomialspace 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

Watchers

 avatar  avatar  avatar

mimixbox's Issues

Need cross platform basic auth.

Issue

There is a process to authenticate the password of the currently logged-in user or another user.
PAM (Pluggable Authenticaton Modules) can be used in the Linux environment, but PAM cannot be used in other environments.
Currently MimixBox only supports Linux environments, but may support * NIX environments in the future.

Expectations

  • Basic authentication switches the method depending on whether or not there is PAM
  • To use the PAM features, we need to install the PAM package. In other words, if we introduce the PAM function, the build will fail in the environment without PAM. Therefore, if we know that there is no PAM at build time, we want to disable the PAM function.

Build mimixbox in Docker.

If I build local source code in Docker, I get an error for an internal package.

no matching versions for query "latest"

Therefore, we are currently copying the binaries built in the HOST environment to the Docker environment.
This method is not preferred because cgo is disabled.
Probably there is a problem with the go mod.

[BUG] wc command test does not succeed on GitHub Actions

Describe the bug
Successful integration test of wc command in local environment.

$ make build
$ sudo make full-install
$ make it

However, integration tests run from GitHub Actions fail.

To Reproduce
Do [IntegrationTest] in GitHub Actions.

Expected behavior
The expected value is to pass a file as an argument to the wc command.
However, the standard input is passed.

The Coreutils wc command doesn't cause similar problems.
I thought that the problem was passing arguments via environment variables,
so I also tested passing arguments as strings. The result was NG.

Screenshots
wc_command_bug

Desktop (please complete the following information):

           ./oydmMMMMMMmdyo/.              nao@nao 
        :smMMMMMMMMMMMhs+:++yhs:           ------- 
     `omMMMMMMMMMMMN+`        `odo`        OS: Ubuntu Budgie 21.04 x86_64 
    /NMMMMMMMMMMMMN-            `sN/       Host: B450 I AORUS PRO WIFI 
  `hMMMMmhhmMMMMMMh               sMh`     Kernel: 5.11.0-40-generic 
 .mMmo-     /yMMMMm`              `MMm.    Uptime: 1 day, 9 hours, 4 mins 
 mN/       yMMMMMMMd-              MMMm    Packages: 3286 (dpkg), 16 (snap) 
oN-        oMMMMMMMMMms+//+o+:    :MMMMo   Shell: bash 5.1.4 
m/          +NMMMMMMMMMMMMMMMMm. :NMMMMm   Resolution: 2560x1080 
M`           .NMMMMMMMMMMMMMMMNodMMMMMMM   DE: Budgie 10.5.2 
M-            sMMMMMMMMMMMMMMMMMMMMMMMMM   WM: Mutter(Budgie) 
mm`           mMMMMMMMMMNdhhdNMMMMMMMMMm   Theme: Yaru-dark [GTK2/3] 
oMm/        .dMMMMMMMMh:      :dMMMMMMMo   Icons: ubuntu-mono-dark [GTK2/3] 
 mMMNyo/:/sdMMMMMMMMM+          sMMMMMm    Terminal: vscode 
 .mMMMMMMMMMMMMMMMMMs           `NMMMm.    CPU: AMD Ryzen 5 3400G (8) @ 3.700GHz 
  `hMMMMMMMMMMM.oo+.            `MMMh`     GPU: AMD ATI 09:00.0 Picasso 
    /NMMMMMMMMMo                sMN/       Memory: 11303MiB / 30034MiB 
     `omMMMMMMMMy.            :dmo`
        :smMMMMMMMh+-`   `.:ohs:                                   
           ./oydmMMMMMMdhyo/.                                      

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.