Homwe is a database query language that uses Shona language constructs. It provides an intuitive way to interact with databases using familiar Shona terms, making database operations more accessible to Shona speakers.
TRY IT HERE: https://homwe-db.pages.dev/
- π Shona-based syntax - Use natural Shona language constructs for database operations
- π¨ Web-based editor - Full-featured Monaco editor with syntax highlighting
- π Real-time execution - See query results instantly
- π Table visualization - Clean, formatted output for query results
- π οΈ CRUD operations - Complete Create, Read, Update, Delete functionality
- π§ͺ Comprehensive testing - Full test suite using Vitest
- Node.js (v16 or higher)
- npm or yarn
# Clone the repository
git clone https://github.com/panasheMuriro/HomweDatabase.git
cd homwe
# Install dependencies
npm install
# Build the grammar
npm run build
# Run tests
npm test
# Start the web editor
npm run devmu homwe mune users
// You can use any of these variants:
users vane name, age, email
users dzine employeeId, department
isa ("John", 25, "john@email.com") mu users
isa ("Jane", 30, "jane@email.com") mu users
// Select all columns
zvese kubva mu users
// Select specific columns
(name, age) kubva mu users
// With WHERE clause
zvese kubva mu users ane age = 25
zvese kubva mu users vane name = "John"
// With LIMIT
zvese kubva mu users 5
chinja age kuita 26 ane name = "John"
chinja email kuita "newemail@test.com" vane age = 30
bvisa users ane age = 25
bvisa users vane name = "John"
After modifying Homwe.g4:
npm run buildThis generates the lexer and parser files in the grammar/build/ directory.
# Run all tests
npm test
# Watch mode
npm run test:watchnpm run devThe editor will be available at http://localhost:5173
| Shona | English Equivalent | Usage |
|---|---|---|
mu homwe mune |
CREATE TABLE | Create a new collection |
ine/vane/dzine... |
HAS/HAVE | Define columns |
isa |
INSERT | Insert values |
kubva mu |
FROM | Select from collection |
zvese |
ALL/SELECT * | Select all columns |
chinja...kuita |
UPDATE...SET | Update values |
bvisa |
DELETE | Delete records |
=- Equality comparison,- List separator()- Grouping/value lists
- Strings:
"text"or'text' - Numbers:
123,45.67 - Null:
_ - Identifiers:
columnName
We welcome contributions! Please follow these steps:
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add some amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
- Write tests for new features
- Update documentation as needed
- Follow the existing code style
- Add Shona translations where appropriate
This project is licensed under the MIT License - see the LICENSE file for details.
- Built with ANTLR4 for parsing
- Uses Monaco Editor for the web interface
- Styled with Tailwind CSS
- Tested with Vitest
For questions, issues, or suggestions:
- Open an issue on GitHub
- Submit a pull request
Β© Shonascript
