update README
This commit is contained in:
parent
4c27e8d99e
commit
5dd0410fb6
124
README.md
124
README.md
@ -2,21 +2,35 @@
|
|||||||
> C source code browser.
|
> C source code browser.
|
||||||
> Fork of Cscope version 15.9, with various improvements.
|
> Fork of Cscope version 15.9, with various improvements.
|
||||||
|
|
||||||
Because cscope is good and shall not be forgotten.
|
Because CScope is good and shall not be forgotten.
|
||||||
While the original's maintenance seems abandoned and as far as I can tell you need a PhD in autoconf to compile the latest version,
|
While the original's maintenance seems abandoned and
|
||||||
|
as far as I can tell you need a PhD in autoconf to compile the latest version,
|
||||||
Csope is alive and well.
|
Csope is alive and well.
|
||||||
|
|
||||||
# Demo
|
## Table of contents
|
||||||
|
- [Demo](#demo)
|
||||||
|
- [Features](#features)
|
||||||
|
- [Interface](#interface)
|
||||||
|
- [Usecases](#usecases)
|
||||||
|
- [Improvements](#improvements)
|
||||||
|
- [Installation](#installation)
|
||||||
|
- [Gentoo](#gentoo)
|
||||||
|
- [From source](#from-source)
|
||||||
|
- [Quick start](#quick-start)
|
||||||
|
- [Configuration](#Configuration)
|
||||||
|
|
||||||
|
## Demo
|
||||||

|

|
||||||
|
|
||||||
# Before/After
|
### Before/After
|
||||||
## After
|
#### After
|
||||||

|

|
||||||
## Before
|
#### Before
|
||||||

|

|
||||||
|
|
||||||
# Features
|
## Features
|
||||||
#### Search for
|
|
||||||
|
**Search for**
|
||||||
+ symbol
|
+ symbol
|
||||||
+ global definition
|
+ global definition
|
||||||
+ assignments to specified symbol
|
+ assignments to specified symbol
|
||||||
@ -26,18 +40,22 @@ Csope is alive and well.
|
|||||||
+ egrep pattern
|
+ egrep pattern
|
||||||
+ file
|
+ file
|
||||||
+ files #including specified file
|
+ files #including specified file
|
||||||
#### ...and open with your editor.
|
|
||||||
#### Batch change search results **interactively**.
|
**...and open with your editor.**
|
||||||
#### Save/load/pipe results.
|
|
||||||
|
**Batch change search results _interactively_.**
|
||||||
|
**Save/load/pipe results.**
|
||||||
|
|
||||||
#### It fully supports:
|
#### It fully supports:
|
||||||
+ C
|
+ C
|
||||||
+ Lex
|
+ Lex
|
||||||
+ Yacc
|
+ Yacc
|
||||||
#### Partially supports
|
#### Partially supports:
|
||||||
+ C++
|
+ C++
|
||||||
+ Java
|
+ Java
|
||||||
|
+ Specification and Description Language
|
||||||
|
|
||||||
# Interface
|
## Interface
|
||||||
<-- Tab -->
|
<-- Tab -->
|
||||||
+--Version-----------------Case--+ +--------------------------------+
|
+--Version-----------------Case--+ +--------------------------------+
|
||||||
A |+--------------+---------------+| |+------------------------------+|
|
A |+--------------+---------------+| |+------------------------------+|
|
||||||
@ -51,16 +69,20 @@ Csope is alive and well.
|
|||||||
V |+--------------+---------------+| |+------------------------------+|
|
V |+--------------+---------------+| |+------------------------------+|
|
||||||
+---------------------Tool Tips--+ +--------------------------------+
|
+---------------------Tool Tips--+ +--------------------------------+
|
||||||
|
|
||||||
# Usacases
|
## Usacases
|
||||||
Csope shines at exploring stranger and obscure code bases due to its TUI.
|
Csope shines at exploring stranger and obscure code bases due to its TUI.
|
||||||
It sometimes gets mislabelled as a code navigation tool, but the original documentation describes it best as a "code browsing tool".
|
It sometimes gets mislabelled as a code navigation tool,
|
||||||
|
but the original documentation describes it best as a "code browsing tool".
|
||||||
Many tools can jump you to a definition or grep for patterns,
|
Many tools can jump you to a definition or grep for patterns,
|
||||||
but Csope is unique in that it allows for those and many other functionalities while providing you with a very comprehensible list of all results,
|
but Csope is unique in that it allows for those and many other functionalities
|
||||||
|
while providing you with a very comprehensible list of all results,
|
||||||
ready to fire up your editor at just the spot.
|
ready to fire up your editor at just the spot.
|
||||||
An example of its excellence is this project. The Cscope code-base used to be a total mess,
|
An example of its excellence is this project. The Cscope code-base used to be a total mess,
|
||||||
fixing it would have been a lost cause, if not for Cscope itself. Well, Csope now.
|
fixing it would have been a lost cause, if not for Cscope itself.
|
||||||
|
Well, Csope now.
|
||||||
|
|
||||||
|
## Improvements/Changes
|
||||||
|
|
||||||
# Improvements/Changes
|
|
||||||
## User side
|
## User side
|
||||||
+ Renamed the program, because "cscope" is annoying to type
|
+ Renamed the program, because "cscope" is annoying to type
|
||||||
+ Improved tui
|
+ Improved tui
|
||||||
@ -68,52 +90,58 @@ fixing it would have been a lost cause, if not for Cscope itself. Well, Csope no
|
|||||||
## To the code
|
## To the code
|
||||||
+ Nuked autoconf, replaced with single Makefile
|
+ Nuked autoconf, replaced with single Makefile
|
||||||
+ Reorganized the control flow
|
+ Reorganized the control flow
|
||||||
+ Encapsulated changes to the TUI into display.c
|
+ Encapsulated various functionalities
|
||||||
+ Encapsulated searching into find.c
|
+ Removed macro hell used for compiling on a dead badgers
|
||||||
+ Removed "scanner.l" which seems to be an ancient version (and redundant copy) of "fscanner.l" forgotten by all
|
+ Reduced global state hell
|
||||||
+ Removed macro hell put in place to allow compiling on a dead badger
|
|
||||||
+ Use stdbool instead of YES/NO macros
|
+ Use stdbool instead of YES/NO macros
|
||||||
+ Saved kilobytes by stripping trailing whitespace
|
+ Removed dead code
|
||||||
+ ...and much more
|
+ ...and much more
|
||||||
|
|
||||||
# Installation
|
## Installation
|
||||||
You will have to compile from source.
|
|
||||||
|
## Gentoo
|
||||||
|
Add [my overlay](https://bis64wqhh3louusbd45iyj76kmn4rzw5ysawyan5bkxwyzihj67c5lid.onion/anon/agvxov-overlay.git)
|
||||||
|
and install using portage.
|
||||||
|
|
||||||
|
## From source
|
||||||
|
|
||||||
After you made sure you have the following installed:
|
After you made sure you have the following installed:
|
||||||
|
+ ncurses
|
||||||
ncurses
|
+ GNU Readline
|
||||||
GNU Readline
|
+ GNU History (should come with Readline)
|
||||||
GNU History (should come with Readline)
|
+ Lex (or GNU Flex)
|
||||||
Lex (or GNU Flex)
|
+ Yacc (or GNU Bison)
|
||||||
Yacc (or GNU Bison)
|
|
||||||
|
|
||||||
Just run:
|
Just run:
|
||||||
|
```sh
|
||||||
make
|
make
|
||||||
|
```
|
||||||
|
|
||||||
This will yield the executable "csope", which you are free to do whatever with.
|
This will yield the executable "csope", which you are free to do whatever with.
|
||||||
|
|
||||||
Hint:
|
Hint:
|
||||||
|
```sh
|
||||||
|
cp csope /usr/bin/
|
||||||
|
```
|
||||||
|
|
||||||
cp csope /usr/bin/
|
## Quick start
|
||||||
|
|
||||||
# Quick start
|
|
||||||
Start browsing your project by running csope over it's source dir.
|
Start browsing your project by running csope over it's source dir.
|
||||||
|
|
||||||
csope -s source/
|
```sh
|
||||||
|
csope -s source/
|
||||||
|
```
|
||||||
|
|
||||||
# Configuration
|
## Configuration
|
||||||
## Readline
|
|
||||||
|
### Readline
|
||||||
The readline integration should be complete -please let us know if not-, except for your prompt being used, which could easily break the TUIs display.
|
The readline integration should be complete -please let us know if not-, except for your prompt being used, which could easily break the TUIs display.
|
||||||
|
|
||||||
The rl_readline_name variable will be set to "Csope", so you may have conditional configurations in your .inputrc with the following format:
|
The `rl_readline_name` variable will be set to "Csope", so you may have conditional configurations in your .inputrc with the following format:
|
||||||
|
```
|
||||||
|
$if Csope
|
||||||
|
# <whatever>
|
||||||
|
$endif
|
||||||
|
```
|
||||||
|
|
||||||
$if Csope
|
### Colors
|
||||||
# <whatever>
|
|
||||||
$endif
|
|
||||||
|
|
||||||
## Colors
|
|
||||||
All can be configured sucklessly under "config/colors.h". Hopefully the comments are self evident.
|
All can be configured sucklessly under "config/colors.h". Hopefully the comments are self evident.
|
||||||
|
|
||||||
# Future features / contributor wishlist
|
|
||||||
+ providing support for other languages by integrating new lexers (e.g. ctag's)
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user