crygen
Version, currently 0.5.014 versions
- 1.3.0latestDec 30, 2025
- 1.2.2not indexedDec 30, 2025
- 1.2.1not indexedDec 30, 2025
- 1.2.0not indexedDec 30, 2025
- 1.1.0not indexedDec 30, 2025
- 1.0.0not indexedDec 30, 2025
- 0.6.0not indexedDec 30, 2025
- 0.5.1not indexedDec 30, 2025
- 0.5.0not indexedDec 30, 2025
- 0.4.0not indexedDec 30, 2025
- 0.3.1not indexedDec 30, 2025
- 0.3.0not indexedDec 30, 2025
- 0.2.0not indexedDec 30, 2025
- 0.1.0not indexedDec 30, 2025
github.com/tamdaz/crygen
A library that allows to generate the Crystal code
Nothing has been indexed for 0.5.0 yet. The tag is recorded, its shard.yml has not been read, so the manifest and dependency list below are empty because they are unknown rather than because they are absent.
Installation
# Add this to your shard.yml
dependencies:
crygen:
github: tamdaz/crygen
version: ~> 0.5.0Then run:
shards installshard.yml
No shard.yml has been indexed for 0.5.0. You can read it on the repository.
Dependencies
Unknown: the shard.yml for this version has not been read yet.
README
This README is the one indexed from the repository at its latest ref, not from the tag for this version.
crygen
crygen is a library that allows to generate a Crystal file. It is inspired by the PHP library : nette/php-generator.
- Crygen documentation: https://tamdaz.github.io/crygen/
- API documentation: https://crystaldoc.info/github/tamdaz/crygen/main/index.html
Installation
- Add the dependency to your
shard.yml:
dependencies:
crygen:
github: tamdaz/crygen
version: ~> 1.3.0
-
Run
shards install -
Finally, import
crygenfrom the entrypoint file:
require "crygen"
module App
VERSION = "1.0.0"
class_type = CGT::Class.new("MyClass")
method_type = CGT::Method.new("my_method", "String")
class_type.add_method(method_type)
puts class_type.generate
# or
puts class_type
# Output:
# class MyClass
# def my_method : String
# end
# end
# You can save the generated code into the .cr file.
File.write("src/classes/my_class.cr", class_type)
end
Contributing
- Fork it (https://github.com/tamdaz/crygen/fork)
- Create your feature branch (
git checkout -b my-new-feature) - Commit your changes (
git commit -am 'Add some feature') - Push to the branch (
git push origin my-new-feature) - Create a new Pull Request
Contributors
Documentation
Built from the current release. The first visit to a release nobody has asked for starts its build.
Links
This release
- Version
0.5.0- Tagged
- Dec 30, 2025
- Commit
957625ddec84- Indexed
- not yet
Dependents
Repository
github.com/tamdaz/crygen
Metadata
- Created
- Aug 12, 2026
- Updated
- Aug 17, 2026
- Synced
- Aug 17, 2026
- Versions
- 14