GithubHelp home page GithubHelp logo

octaspire / acme-setup Goto Github PK

View Code? Open in Web Editor NEW
0.0 1.0 1.0 13 KB

Scripts to be used with the Acme editor.

License: Other

Makefile 18.22% Shell 18.20% Python 63.59%
acme plan9port tags code-navigation code-completion function-signature

acme-setup's Introduction

Octaspire's Acme Setup

Scripts to be used with the Acme editor; mainly when using Plan 9 from User Space. Contains:

  • octaspire_acme: Run this command instead of acme to make sure that plumber and fontsrv are running before Acme is started. Will start Acme with some specific settings and font. Will also load acme.dump if available (this restores the workspace and gives also functionality similar to 'Goto Last Change' in GNU/Emacs).

  • octaspire_project_root: Run command '. octaspire_project_root' (please note the dot in the beginning) in the root directory of the project you want to work with. This command can be used to set or change environment variable OCTASPIRE_PROJECT_ROOT that should point to the root directory of the project.

  • octaspire_tags_up: Takes care of creating and updating TAGS (universal-ctags) files so that the user never has to do it. Detects changes currently using modification time of files; more robust solution would be checksumming the files.

  • octaspire_tags_find: Locates definition of the highlighted name and reports it as filename:linenum pair, so that the file and correct line can be easily jumped to using the third mouse button.

  • octaspire_tags_complete: Lists completion suggestions for the highlighted (partial) name. Matches are looked for and sorted fuzzily using Levenshtein distances. Philosophical Note: I think that code completion might encourage use of overlong names and thus it might be something that should not be done; instead the situation might be fixed by just using shorter names.

  • octaspire_tags_signature: Reports function signature for the C function, that has its name highlighted.

Requirements

UNIX like operating system, Plan 9 from User Space, universal ctags and Python 3 with fuzzywuzzy package, that can be installed using:

pip install --user fuzzywuzzy[speedup]

To lint the scripts, shellcheck and pylint are also needed. To proofread the README.md as HTML, markdown_py is required.

Acme is started with font Inconsolata-Regular, and thus that font should be available on the system (otherwise another font should be selected in the octaspire_acme-script).

Usage

Copy executables into a directory that is on your path. If $HOME/bin is on your path, you can copy files like this:

make install

First of all, the environment variable OCTASPIRE_PROJECT_ROOT must point to the root directory of the project you want to work with. It can be exported like any other environment variable in .profile or some other file, but it can be also set and changed using command:

cd some/project/
. octaspire_project_root

Then Acme can be started using:

octaspire_acme

Other commands can be run by writing and selecting them from the tag:

> octaspire_tags_find  > octaspire_tags_complete  > octaspire_tags_signature

License

Apache License, Version 2.0

acme-setup's People

Contributors

octaspire avatar

Watchers

 avatar

Forkers

tkslide

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.