Coder Social home page Coder Social logo

phatevalleyman / mkshrc Goto Github PK

View Code? Open in Web Editor NEW

This project forked from magisk-modules-alt-repo/mkshrc

0.0 0.0 0.0 55.44 MB

Systemlessly mksh.rc for better Terminal experience to turn your device into a workstation :)

License: GNU General Public License v3.0

Shell 0.25% JavaScript 0.36% Ruby 0.35% Python 0.03% Perl 0.53% C 0.23% Emacs Lisp 0.29% Smalltalk 0.25% Awk 0.01% SystemVerilog 0.27% Makefile 0.01% NewLisp 0.36% PostScript 0.62% Batchfile 0.01% Roff 0.04% Vim Script 96.40%

mkshrc's Introduction

Systemless Mkshrc

Systemlessly Mkshrc for better Terminal experience to turn your device into a workstation :)

FIRST RUN!

DO SHOULD NOT RUN BASH WITH THIS MODULE

You should after the installation su in any terminal, to initialize the user/app folders. Every app has its own folder based on his username (/data/chuser/root).

Important

Module mkshrc

Supporting mkshrc for every own magisk module, just simply create <MODID>/system/etc/mkshrc.d/<name>.d.sh

Supported APIs:

  • sudo
  • setperm
  • setperm:insecure
    • This method uses root permissions. If you prefer an safer way please use setperm

Extended usage

There are more things to import:

How to import:

source $MKLIB/<folder>/<file>.sh

core/installed

Check if mkshrc is installed

[ -z $MKLIB ] && echo "Source fail!" && exit 122;

console/abort

# abort <code> <content>
abort 404 "Your file does not exist"

console/ui_print

# Available colors: none, red, green, yellow, white, cyan
ui_print cyan "Logged content"

util/setperm

⚠️ This file includes insecure methods

setperm $PREFIX/bin/* $USERID $USERID 0755

# Uses sudo in the backend
setperm:insecure $PREFIX/bin/* $USERID $USERID 0755

util/sudo

sudo ls

util/grepprop

⚠️ This file includes insecure methods

grepprop id /data/adb/modules/mkshrc/module.prop

# Uses sudo in the backend
grepprop:insecure id /data/adb/modules/mkshrc/module.prop

util/f2c

Alpha Fox2Code library parts. Thanks for the concept of this!

mkshrc-setenv "TEST_ENV" "Yolo"
mkshrc-getenv "TEST_ENV" # output: Yolo

mkshrc-add-path /data/bin \
          /system/bin

resolv.conf

Cloudflare

nameserver 1.1.1.1
nameserver 1.0.0.1

Google

nameserver 8.8.4.4
nameserver 8.8.8.8

mkshrc's People

Contributors

dergoogler avatar

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.