Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added missing keyword: AUTHOR #2

Open
wants to merge 25 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
ba301a6
Added missing keyword: AUTHOR
EmmasBox Aug 8, 2023
242b977
Updated .gitignore to ignore .vscode and .idea
EmmasBox Aug 15, 2023
b210869
Improved TypeScript support
EmmasBox Aug 15, 2023
01c2d6f
Changed number recognition to not recognize numbers part of names (su…
EmmasBox Aug 15, 2023
bd17e72
Cleaned up package.json
EmmasBox Aug 15, 2023
495ee10
Cleaned up package.json
EmmasBox Aug 15, 2023
452277c
Improved operator regex
EmmasBox Aug 15, 2023
cc2308d
Fixed package.json name
EmmasBox Aug 15, 2023
518ae2b
Fixed package.json repository url
EmmasBox Aug 15, 2023
5224b4e
Fixed typescript types path in package.json
EmmasBox Aug 15, 2023
2e7d230
Deleted unnecessary files
EmmasBox Aug 15, 2023
5873219
Reset package-lock.json
EmmasBox Aug 15, 2023
f3e7c96
Reset package-lock.json
EmmasBox Aug 15, 2023
22cacdd
Various changes
EmmasBox Aug 15, 2023
84efca5
updated name
EmmasBox Aug 15, 2023
24addfe
Update README.md
EmmasBox Aug 15, 2023
f0f9783
Updated package.json keywords and used the proper method of handling …
EmmasBox Aug 15, 2023
9764eea
Merge remote-tracking branch 'origin/main'
EmmasBox Aug 15, 2023
fa61cbf
Fixed typescript support
EmmasBox Aug 15, 2023
7ac3868
Fixed typescript support
EmmasBox Aug 15, 2023
73ff975
Reverted bad change
EmmasBox Aug 15, 2023
2d574a5
Potentially fixed a small bug in the highlightin of "PROGRAM-ID"
EmmasBox Aug 15, 2023
74c24d8
Fixed a bug that would cause incorrect syntax highlighting of numbers
EmmasBox Mar 30, 2024
2fedcb2
Updated dependencies and improved number recognition
EmmasBox Apr 1, 2024
664c53d
Update README.md
EmmasBox Sep 28, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1 +1,3 @@
node_modules
node_modules
.vscode
.idea
13 changes: 0 additions & 13 deletions .vscode/settings.json

This file was deleted.

64 changes: 9 additions & 55 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,62 +1,16 @@
# COBOL - syntax highlighting for [highlight.js](https://highlightjs.org/)
[![version](https://badgen.net/npm/v/highlightjs-enterprisecobol)](https://www.npmjs.com/package/highlightjs-enterprisecobol) [![license](https://badgen.net/badge/license/apache2.0)](./LICENSE)

![version](https://badgen.net/npm/v/highlightjs-cobol) ![license](https://badgen.net/badge/license/apache2.0)
# Enterprise COBOL - syntax highlighting for highlight.js

COBOL is a statically typed, imperative, procedural programming language with support for object oriented programming. First released in 1959, it's still used today in many banking and financial companies due to it's decimal arithmetic, making it well suited for financial calculations.
Based on the otterkit package: https://github.com/otterkit/highlightjs-cobol, contains several improvements as of the writing:
Better regex (several bugs fixed and minor optimization done), better TypeScript support, and AUTHOR has been added to the list of reserved words so it will be highlighted (just like IBM Z Open Editor's highlighter does).

## Usage

Warning: This syntax highlighter is designed to work with __fixed-form only__ and won't work
properly with free-form COBOL code.
Simply include the Highlight.js library in your webpage or Node app, then load this module.
# Installation
Simply add highlightjs-enterprisecobol to your dependencies in your package.json (requires highlight.js to be installed). Install using npm

### Static website or simple usage
# Links

Simply load the module after loading Highlight.js. You'll use the minified version found in the `dist` directory. This module is just a CDN build of the language, so it will register itself as the Javascript is loaded.
The official site for the Highlight.js library is https://highlightjs.org/

```html
<script type="text/javascript" src="/path/to/highlight.min.js"></script>
<script type="text/javascript" charset="UTF-8"
src="/path/to/highlightjs-cobol/dist/cobol.min.js"></script>
<script type="text/javascript">
hljs.highlightAll();
</script>
```

### Using directly from the UNPKG CDN

```html
<script type="text/javascript"
src="https://unpkg.com/highlightjs-cobol/dist/cobol.min.js"></script>
```

- More info: <https://unpkg.com>

### With Node or another build system

If you're using Node / Webpack / Rollup / Browserify, etc, simply require the language module, then register it with Highlight.js.

```javascript
var hljs = require('highlightjs');
var hljsCOBOL = require('highlightjs-cobol');

hljs.registerLanguage("cobol", hljsCOBOL);
hljs.highlightAll();
```


## License

highlightjs-cobol is released under the Apache 2.0 License. See [LICENSE][1] file
for details.

### Author / Maintainer

Gabriel Gonçalves <[email protected]>

## Links

- The official site for the Highlight.js library is <https://highlightjs.org/>.
- The Highlight.js GitHub project: <https://github.com/highlightjs/highlight.js>

[1]: https://github.com/otterkit/highlightjs-cobol/blob/master/LICENSE
The Highlight.js GitHub project: https://github.com/highlightjs/highlight.js
12 changes: 0 additions & 12 deletions dist/cobol.es.min.js

This file was deleted.

12 changes: 0 additions & 12 deletions dist/cobol.min.js

This file was deleted.

Loading