mirror of
https://github.com/soconnor0919/tree-sitter-hack-binary.git
synced 2026-02-04 15:56:30 -05:00
Add README, .gitignore, and clean up build artifacts
- Added comprehensive README with usage instructions - Added .gitignore to prevent build artifacts from being committed - Removed target/ directories and duplicate WASM files - Cleaned up parser binaries and test files
This commit is contained in:
25
.gitignore
vendored
Normal file
25
.gitignore
vendored
Normal file
@@ -0,0 +1,25 @@
|
|||||||
|
# Build artifacts
|
||||||
|
target/
|
||||||
|
*.wasm
|
||||||
|
*.dylib
|
||||||
|
*.so
|
||||||
|
*.dll
|
||||||
|
*.dylib
|
||||||
|
*.a
|
||||||
|
*.o
|
||||||
|
|
||||||
|
# Node modules
|
||||||
|
node_modules/
|
||||||
|
|
||||||
|
# IDE files
|
||||||
|
.vscode/
|
||||||
|
.idea/
|
||||||
|
*.swp
|
||||||
|
*.swo
|
||||||
|
|
||||||
|
# OS files
|
||||||
|
.DS_Store
|
||||||
|
Thumbs.db
|
||||||
|
|
||||||
|
# Logs
|
||||||
|
*.log
|
||||||
48
README.md
Normal file
48
README.md
Normal file
@@ -0,0 +1,48 @@
|
|||||||
|
# tree-sitter-hack-binary
|
||||||
|
|
||||||
|
A [Tree-sitter](https://tree-sitter.github.io/tree-sitter/) grammar for Hack Binary machine code as used in the [nand2tetris](https://www.nand2tetris.org/) course.
|
||||||
|
|
||||||
|
## Supported File Types
|
||||||
|
|
||||||
|
- `.hack` - Hack Binary machine code files
|
||||||
|
|
||||||
|
## Features
|
||||||
|
|
||||||
|
- **Syntax highlighting** for 16-bit binary instructions
|
||||||
|
- **Code navigation** with outline support
|
||||||
|
- **Integration** with Zed editor and other Tree-sitter compatible editors
|
||||||
|
|
||||||
|
## Usage
|
||||||
|
|
||||||
|
This grammar is designed to work with the [nand2tetris-zed](https://github.com/soconnor0919/nand2tetris-zed) extension for Zed editor, providing complete language support for the nand2tetris course.
|
||||||
|
|
||||||
|
## Grammar Details
|
||||||
|
|
||||||
|
- **Language**: Hack Binary
|
||||||
|
- **Scope**: `source.hack_binary`
|
||||||
|
- **File Types**: `.hack`
|
||||||
|
|
||||||
|
## Development
|
||||||
|
|
||||||
|
### Building
|
||||||
|
|
||||||
|
```bash
|
||||||
|
# Generate parser
|
||||||
|
tree-sitter generate
|
||||||
|
|
||||||
|
# Build parser
|
||||||
|
tree-sitter build
|
||||||
|
|
||||||
|
# Test grammar
|
||||||
|
tree-sitter test
|
||||||
|
```
|
||||||
|
|
||||||
|
## License
|
||||||
|
|
||||||
|
MIT License - see [LICENSE](LICENSE) file for details.
|
||||||
|
|
||||||
|
## Related
|
||||||
|
|
||||||
|
- [nand2tetris-zed](https://github.com/soconnor0919/nand2tetris-zed) - Complete Zed extension
|
||||||
|
- [nand2tetris.org](https://www.nand2tetris.org/) - Course website
|
||||||
|
- [Tree-sitter](https://tree-sitter.github.io/tree-sitter/) - Parser generator
|
||||||
BIN
parser.dylib
BIN
parser.dylib
Binary file not shown.
Reference in New Issue
Block a user