Giter Club home page Giter Club logo

xv6-editor's Introduction

xv6-editor

NOTICE: My xv6 runs in QEMU simulator.

The folder xv6_all_files contains all the original code and all the executable file of xv6-rev7(release version 7) system.

editor.c file contains the main code of my simple editor.

The simple editor can simply highlight the C language. Its effect is demostrated below.

code highlight demo

This editor can mostly undo 20 steps sequently. It depends on the variable MAX_ROLLBACK_STEP. If you want more undo step, just extend this variable. There is a small bug with undo delete command. Unfortunately, it still has not been resolved though I have paid a lot of time on it. I suspect that I triggered a unfound system bug. Who knows? But don't worry about that. This small bug just limit our ability to undo the delete operation and I have forbidden this function. The other function wouldn't be affected. So you can use this editor safely. I have mark the code which with bug in the editor.c.

Furthermore, press help instruction for more operating detail. All the operations are here.

help info


How to install xv6?

Execute the following instructions sequently.

1. Install the gdb and gcc.

sudo apt-get install -y build-essential gdb 
sudo apt-get install gcc-multilib

2. Install QEMU simulator.

sudo apt-get install qemu

3. Clone origin xv6 code from github.

git clone git://github.com/mit-pdos/xv6-public.git

4. Rollback to rev7 version.

tips: rev7 version is more stable and reliable.

cd xv6-public-master
git checkout -b xv6-rev7 xv6-rev7

5. Open the Makefile file, find the following line and complete it.

QEMU = qemu-system-x86_64

6. Now you can compile xv6 system.

make

7. If you see the following info, Congratulations! you have successfully compiled it.

successfully compiled info

8. Now you can open xv6 and enjoy it.

make qemu-nox

Running


There is still a problem existing. How to compile xv6 with your own C file?

We should know the fact that how make instruction compiles xv6 system is depending on Makefile. So we should add something properly to Makefile file.

  1. Open Makefile file.

  2. Find out the following two parts of code and add the content which circled with red box.

    revise_Makefile_1

    revise_Makefile_2

  3. Then save Makefile and compile xv6 again.

xv6-editor's People

Contributors

0xnefelibata avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Forkers

git-prudhvi

xv6-editor's Issues

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.