synthra 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/.rspec +4 -0
- data/.rubocop.yml +40 -0
- data/.yardopts +18 -0
- data/ACCESS_DOCS.md +116 -0
- data/ADVANCED_FEATURES_SUMMARY.md +245 -0
- data/CHANGELOG.md +498 -0
- data/CODE_OF_CONDUCT.md +122 -0
- data/CONTRIBUTING.md +307 -0
- data/DOCUMENTATION.md +204 -0
- data/DOCUMENTATION_GUIDE.md +194 -0
- data/LICENSE +22 -0
- data/README.md +1458 -0
- data/Rakefile +128 -0
- data/benchmark/README.md +591 -0
- data/benchmark/batch_generation.rb +63 -0
- data/benchmark/engine_comparison.rb +295 -0
- data/benchmark/single_record.rb +108 -0
- data/benchmark/streaming.rb +74 -0
- data/docs/ACTIVERECORD_INFERENCE.md +524 -0
- data/docs/API_SERVER.md +278 -0
- data/docs/CONFIG_FILE.md +315 -0
- data/docs/DATA_CONTRACTS.md +312 -0
- data/docs/ENHANCED_REPL.md +304 -0
- data/docs/FACTORY_BOT.md +271 -0
- data/docs/GITHUB_ACTION.md +420 -0
- data/docs/GRAPHQL_EXPORT.md +303 -0
- data/docs/GRAPHQL_FEDERATION.md +651 -0
- data/docs/HOW_TO_GENERATE_DOCS.md +252 -0
- data/docs/LSP.md +189 -0
- data/docs/MIGRATION_GENERATOR.md +547 -0
- data/docs/MOCK_SERVER.md +280 -0
- data/docs/NATIVE_ENGINE.md +298 -0
- data/docs/OPENAPI_EXPORT.md +252 -0
- data/docs/PERFORMANCE_MODE.md +228 -0
- data/docs/PERSONAS.md +547 -0
- data/docs/PROPERTY_TESTING.md +284 -0
- data/docs/PROTOBUF_EXPORT.md +276 -0
- data/docs/QUALITY_METRICS.md +555 -0
- data/docs/QUICK_REFERENCE.md +88 -0
- data/docs/RAILS_ENGINE.md +404 -0
- data/docs/RAILS_INTEGRATION.md +454 -0
- data/docs/README.md +175 -0
- data/docs/REPL_QUICK_REFERENCE.md +149 -0
- data/docs/RUST_INTEGRATION_GUIDE.md +1376 -0
- data/docs/SCENARIOS.md +576 -0
- data/docs/SECURITY_TESTING.md +318 -0
- data/docs/SNAPSHOT_TESTING.md +308 -0
- data/docs/STRING_TEXT_TYPES_REFERENCE.md +512 -0
- data/docs/TERRAFORM_EXPORT.md +447 -0
- data/docs/TIME_TRAVEL.md +507 -0
- data/docs/USAGE_GUIDE.md +980 -0
- data/docs/WEBHOOK_SIMULATOR.md +579 -0
- data/docs/advanced_features.md +183 -0
- data/docs/api_reference.md +153 -0
- data/docs/behaviors.md +138 -0
- data/docs/best_practices.md +191 -0
- data/docs/dsl_reference.md +172 -0
- data/docs/examples.md +162 -0
- data/docs/generation_modes.md +125 -0
- data/docs/getting_started.md +92 -0
- data/docs/index.html +177 -0
- data/docs/strategic/CLOUD_REGISTRY_ARCHITECTURE.md +268 -0
- data/docs/strategic/SIMD_OPTIMIZATION_STRATEGY.md +153 -0
- data/docs/troubleshooting.md +215 -0
- data/docs/type_reference.md +224 -0
- data/examples/hostile_mode_demo.rb +64 -0
- data/exe/synthra +6 -0
- data/ext/synthra_native/Cargo.lock +972 -0
- data/ext/synthra_native/Cargo.toml +46 -0
- data/ext/synthra_native/extconf.rb +41 -0
- data/ext/synthra_native/src/generator.rs +397 -0
- data/ext/synthra_native/src/lib.rs +229 -0
- data/ext/synthra_native/src/types.rs +1485 -0
- data/lib/generators/synthra/install_generator.rb +86 -0
- data/lib/generators/synthra/templates/api_response.dsl +15 -0
- data/lib/generators/synthra/templates/fake_data.rake +116 -0
- data/lib/generators/synthra/templates/synthra.yml +31 -0
- data/lib/generators/synthra/templates/synthra_support.rb +19 -0
- data/lib/generators/synthra/templates/user.dsl +11 -0
- data/lib/synthra/activerecord_inference.rb +394 -0
- data/lib/synthra/api.rb +381 -0
- data/lib/synthra/api_server.rb +718 -0
- data/lib/synthra/behaviors/applicator.rb +165 -0
- data/lib/synthra/behaviors/base.rb +155 -0
- data/lib/synthra/behaviors/close_connection.rb +60 -0
- data/lib/synthra/behaviors/deprecated.rb +100 -0
- data/lib/synthra/behaviors/failure.rb +69 -0
- data/lib/synthra/behaviors/latency.rb +103 -0
- data/lib/synthra/behaviors/partial_data.rb +83 -0
- data/lib/synthra/behaviors/randomize_order.rb +74 -0
- data/lib/synthra/behaviors/registry.rb +238 -0
- data/lib/synthra/behaviors/simulate_error.rb +79 -0
- data/lib/synthra/cli/commands/base.rb +105 -0
- data/lib/synthra/cli/commands/diff.rb +227 -0
- data/lib/synthra/cli/commands/docs.rb +67 -0
- data/lib/synthra/cli/commands/export.rb +150 -0
- data/lib/synthra/cli/commands/generate.rb +72 -0
- data/lib/synthra/cli/commands/import.rb +80 -0
- data/lib/synthra/cli/commands/lint.rb +53 -0
- data/lib/synthra/cli/commands/live.rb +57 -0
- data/lib/synthra/cli/commands/seed.rb +99 -0
- data/lib/synthra/cli/commands/validate.rb +28 -0
- data/lib/synthra/cli.rb +2471 -0
- data/lib/synthra/config_file.rb +129 -0
- data/lib/synthra/configuration.rb +281 -0
- data/lib/synthra/contracts_registry.rb +408 -0
- data/lib/synthra/database_seeder.rb +268 -0
- data/lib/synthra/deterministic_ids.rb +218 -0
- data/lib/synthra/documentation_generator.rb +414 -0
- data/lib/synthra/engine.rb +251 -0
- data/lib/synthra/errors.rb +1169 -0
- data/lib/synthra/export/base.rb +85 -0
- data/lib/synthra/export/csv.rb +101 -0
- data/lib/synthra/export/graphql.rb +266 -0
- data/lib/synthra/export/graphql_federation.rb +377 -0
- data/lib/synthra/export/graphviz.rb +258 -0
- data/lib/synthra/export/javascript.rb +327 -0
- data/lib/synthra/export/json_data.rb +61 -0
- data/lib/synthra/export/json_schema.rb +290 -0
- data/lib/synthra/export/openapi.rb +514 -0
- data/lib/synthra/export/protobuf.rb +483 -0
- data/lib/synthra/export/python.rb +560 -0
- data/lib/synthra/export/sql.rb +381 -0
- data/lib/synthra/export/sql_insert.rb +152 -0
- data/lib/synthra/export/terraform.rb +501 -0
- data/lib/synthra/export/type_mapping.rb +389 -0
- data/lib/synthra/export/typescript.rb +300 -0
- data/lib/synthra/export/xml_data.rb +104 -0
- data/lib/synthra/export/yaml_data.rb +56 -0
- data/lib/synthra/export.rb +404 -0
- data/lib/synthra/factory_bot_integration.rb +157 -0
- data/lib/synthra/field.rb +440 -0
- data/lib/synthra/functions/registry.rb +104 -0
- data/lib/synthra/generator/context.rb +372 -0
- data/lib/synthra/generator/engine.rb +336 -0
- data/lib/synthra/generator/faker_adapter.rb +425 -0
- data/lib/synthra/generator/modes.rb +444 -0
- data/lib/synthra/generator/resolver.rb +256 -0
- data/lib/synthra/generator/rng.rb +273 -0
- data/lib/synthra/generator/streamer.rb +63 -0
- data/lib/synthra/generator/uniqueness.rb +118 -0
- data/lib/synthra/initializer.rb +97 -0
- data/lib/synthra/limits.rb +279 -0
- data/lib/synthra/live_preview.rb +518 -0
- data/lib/synthra/loader_config.rb +78 -0
- data/lib/synthra/lsp/server.rb +689 -0
- data/lib/synthra/migration_generator.rb +301 -0
- data/lib/synthra/mixin.rb +174 -0
- data/lib/synthra/mock_server.rb +458 -0
- data/lib/synthra/native_engine.rb +304 -0
- data/lib/synthra/openapi_importer.rb +228 -0
- data/lib/synthra/output/json_formatter.rb +40 -0
- data/lib/synthra/output/ndjson_formatter.rb +55 -0
- data/lib/synthra/parser/ast.rb +1287 -0
- data/lib/synthra/parser/lexer.rb +1152 -0
- data/lib/synthra/parser/parser.rb +1664 -0
- data/lib/synthra/parser/tokens.rb +461 -0
- data/lib/synthra/performance_mode.rb +364 -0
- data/lib/synthra/personas.rb +397 -0
- data/lib/synthra/property_testing.rb +172 -0
- data/lib/synthra/quality_metrics.rb +405 -0
- data/lib/synthra/rails_test_helper.rb +248 -0
- data/lib/synthra/registry.rb +533 -0
- data/lib/synthra/relationships.rb +193 -0
- data/lib/synthra/repl/enhanced_repl.rb +607 -0
- data/lib/synthra/repl/formatter.rb +191 -0
- data/lib/synthra/scenarios.rb +423 -0
- data/lib/synthra/schema.rb +605 -0
- data/lib/synthra/schema_inheritance.rb +104 -0
- data/lib/synthra/schema_versioning.rb +212 -0
- data/lib/synthra/snapshot_testing.rb +199 -0
- data/lib/synthra/time_travel.rb +338 -0
- data/lib/synthra/type_definitions.rb +274 -0
- data/lib/synthra/types/address_location/addresses.rb +125 -0
- data/lib/synthra/types/address_location/airports.rb +200 -0
- data/lib/synthra/types/address_location/banks_hospitals.rb +207 -0
- data/lib/synthra/types/address_location/locations.rb +406 -0
- data/lib/synthra/types/base.rb +48 -0
- data/lib/synthra/types/commerce_products/commerce.rb +119 -0
- data/lib/synthra/types/commerce_products/companies.rb +71 -0
- data/lib/synthra/types/commerce_products/construction.rb +126 -0
- data/lib/synthra/types/commerce_products/products.rb +205 -0
- data/lib/synthra/types/core/collections.rb +513 -0
- data/lib/synthra/types/core/defaults.rb +76 -0
- data/lib/synthra/types/core/enums.rb +102 -0
- data/lib/synthra/types/core/identifiers.rb +445 -0
- data/lib/synthra/types/core/primitives.rb +586 -0
- data/lib/synthra/types/core/references.rb +466 -0
- data/lib/synthra/types/core/sequences.rb +304 -0
- data/lib/synthra/types/crypto/crypto.rb +162 -0
- data/lib/synthra/types/date_time/dates.rb +387 -0
- data/lib/synthra/types/finance_banking/banking.rb +424 -0
- data/lib/synthra/types/finance_banking/credit_cards.rb +24 -0
- data/lib/synthra/types/finance_banking/identifiers.rb +93 -0
- data/lib/synthra/types/formula.rb +184 -0
- data/lib/synthra/types/health_medical/medical.rb +150 -0
- data/lib/synthra/types/hostile_payloads.rb +122 -0
- data/lib/synthra/types/json_array.rb +51 -0
- data/lib/synthra/types/media_entertainment/media.rb +62 -0
- data/lib/synthra/types/naughty_string.rb +30 -0
- data/lib/synthra/types/personal_names/chinese.rb +41 -0
- data/lib/synthra/types/personal_names/identifiers.rb +187 -0
- data/lib/synthra/types/personal_names/names.rb +246 -0
- data/lib/synthra/types/personal_names/national_id.rb +89 -0
- data/lib/synthra/types/personal_names/titles_suffixes.rb +41 -0
- data/lib/synthra/types/regex.rb +248 -0
- data/lib/synthra/types/registry.rb +182 -0
- data/lib/synthra/types/repeating_element.rb +50 -0
- data/lib/synthra/types/scenario.rb +29 -0
- data/lib/synthra/types/technology_internet/apps.rb +67 -0
- data/lib/synthra/types/technology_internet/communication.rb +162 -0
- data/lib/synthra/types/technology_internet/devices.rb +80 -0
- data/lib/synthra/types/technology_internet/formats.rb +139 -0
- data/lib/synthra/types/technology_internet/networking.rb +143 -0
- data/lib/synthra/types/template.rb +92 -0
- data/lib/synthra/types/text_content/business.rb +128 -0
- data/lib/synthra/types/text_content/colors.rb +70 -0
- data/lib/synthra/types/text_content/misc.rb +237 -0
- data/lib/synthra/types/text_content/security.rb +130 -0
- data/lib/synthra/types/text_content/text_generation.rb +532 -0
- data/lib/synthra/types/travel/travel.rb +150 -0
- data/lib/synthra/utils/string_distance.rb +133 -0
- data/lib/synthra/validator/dsl_validator.rb +339 -0
- data/lib/synthra/validator/path_validator.rb +615 -0
- data/lib/synthra/version.rb +35 -0
- data/lib/synthra/webhook_simulator.rb +341 -0
- data/lib/synthra.rb +259 -0
- data/schemas/address.dsl +16 -0
- data/schemas/api_response.dsl +8 -0
- data/schemas/error_payload.dsl +9 -0
- data/schemas/order.dsl +10 -0
- data/schemas/order_item.dsl +8 -0
- data/schemas/payment.dsl +11 -0
- data/schemas/social_post.dsl +13 -0
- data/schemas/user.dsl +10 -0
- data/scripts/batch_fix_all.rb +96 -0
- data/scripts/delete_old_files.rb +32 -0
- data/scripts/fix_all_grouped_files.rb +137 -0
- data/scripts/fix_all_indentation.rb +48 -0
- data/scripts/fix_all_syntax.rb +124 -0
- data/scripts/fix_grouped_files.rb +184 -0
- data/scripts/fix_syntax_errors.rb +108 -0
- data/scripts/group_domain_types.rb +112 -0
- data/scripts/group_domain_types_fixed.rb +150 -0
- data/scripts/merge_domains_to_one_file.rb +68 -0
- data/scripts/move_existing_types.rb +130 -0
- data/scripts/split_grouped_types.rb +142 -0
- data/tech_docs/README.md +134 -0
- data/tech_docs/advanced/streaming.md +405 -0
- data/tech_docs/advanced/thread_safety.md +253 -0
- data/tech_docs/api/overview.md +485 -0
- data/tech_docs/appendices/type_chart.md +193 -0
- data/tech_docs/basic_concepts.md +383 -0
- data/tech_docs/behaviors/overview.md +346 -0
- data/tech_docs/dsl/complex_types.md +790 -0
- data/tech_docs/dsl/core_types.md +464 -0
- data/tech_docs/dsl/datetime_types.md +325 -0
- data/tech_docs/dsl/field_modifiers.md +414 -0
- data/tech_docs/dsl/grammar.md +431 -0
- data/tech_docs/dsl/schema_definition.md +399 -0
- data/tech_docs/export/README.md +276 -0
- data/tech_docs/installation.md +273 -0
- data/tech_docs/integration/ci_cd.md +707 -0
- data/tech_docs/integration/ci_cd_guide.md +579 -0
- data/tech_docs/integration/factory_bot.md +485 -0
- data/tech_docs/integration/rails.md +630 -0
- data/tech_docs/integration/rspec.md +449 -0
- data/tech_docs/modes/overview.md +350 -0
- data/tech_docs/performance/NATIVE_RUST_EXTENSION.md +1270 -0
- data/tech_docs/performance/OPTIMIZATION_GUIDE.md +901 -0
- data/tech_docs/quick_start.md +256 -0
- data/tech_docs/templates/README.md +805 -0
- data/tech_docs/tutorials/advanced.md +371 -0
- data/tech_docs/tutorials/getting_started.md +189 -0
- data/tech_docs/tutorials/intermediate.md +231 -0
- data/tech_docs/tutorials/template_gallery.md +569 -0
- data/tech_example/01_basic_usage.rb +238 -0
- data/tech_example/02_types_demo.rb +336 -0
- data/tech_example/04_cli_usage.md +429 -0
- data/tech_example/05_database_seeding.rb +283 -0
- data/tech_example/07_rspec_integration.rb +359 -0
- data/tech_example/10_custom_types.rb +387 -0
- data/tech_example/12_behaviors.rb +372 -0
- data/tech_example/13_twitter_dm_example.rb +120 -0
- data/tech_example/14_exact_json_structure.rb +253 -0
- data/tech_example/16_lsp_server.rb +56 -0
- data/tech_example/17_property_testing.rb +92 -0
- data/tech_example/18_enhanced_repl.rb +120 -0
- data/tech_example/19_security_fuzzing.rb +145 -0
- data/tech_example/NEW_FEATURES.md +169 -0
- data/tech_example/README.md +118 -0
- data/tech_example/schemas/api_response.dsl +123 -0
- data/tech_example/schemas/ecommerce.dsl +121 -0
- data/tech_example/schemas/twitter_dm.dsl +109 -0
- data/tech_example/schemas/user.dsl +36 -0
- data/vscode-extension/README.md +246 -0
- data/vscode-extension/language-configuration.json +31 -0
- data/vscode-extension/package.json +55 -0
- data/vscode-extension/snippets/fakedatadsl.json +198 -0
- data/vscode-extension/syntaxes/fakedatadsl.tmLanguage.json +128 -0
- metadata +478 -0
data/CONTRIBUTING.md
ADDED
|
@@ -0,0 +1,307 @@
|
|
|
1
|
+
# Contributing to FakeDataDSL
|
|
2
|
+
|
|
3
|
+
Thank you for your interest in contributing to FakeDataDSL! This document provides guidelines and information for contributors.
|
|
4
|
+
|
|
5
|
+
## Table of Contents
|
|
6
|
+
|
|
7
|
+
- [Code of Conduct](#code-of-conduct)
|
|
8
|
+
- [Getting Started](#getting-started)
|
|
9
|
+
- [Development Setup](#development-setup)
|
|
10
|
+
- [How to Contribute](#how-to-contribute)
|
|
11
|
+
- [Pull Request Process](#pull-request-process)
|
|
12
|
+
- [Code Style](#code-style)
|
|
13
|
+
- [Testing Guidelines](#testing-guidelines)
|
|
14
|
+
- [Documentation](#documentation)
|
|
15
|
+
|
|
16
|
+
## Code of Conduct
|
|
17
|
+
|
|
18
|
+
This project adheres to a Code of Conduct. By participating, you are expected to uphold this code. Please report unacceptable behavior to the maintainers.
|
|
19
|
+
|
|
20
|
+
## Getting Started
|
|
21
|
+
|
|
22
|
+
1. Fork the repository on GitHub
|
|
23
|
+
2. Clone your fork locally:
|
|
24
|
+
```bash
|
|
25
|
+
git clone https://github.com/YOUR_USERNAME/fake_data_dsl.git
|
|
26
|
+
cd fake_data_dsl
|
|
27
|
+
```
|
|
28
|
+
3. Add the upstream remote:
|
|
29
|
+
```bash
|
|
30
|
+
git remote add upstream https://github.com/talaatmagdyx/fake_data_dsl.git
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
## Development Setup
|
|
34
|
+
|
|
35
|
+
### Prerequisites
|
|
36
|
+
|
|
37
|
+
- Ruby 3.1.0 or higher
|
|
38
|
+
- Bundler 2.0+
|
|
39
|
+
|
|
40
|
+
### Installation
|
|
41
|
+
|
|
42
|
+
```bash
|
|
43
|
+
# Install dependencies
|
|
44
|
+
bundle install
|
|
45
|
+
|
|
46
|
+
# Run tests to verify setup
|
|
47
|
+
bundle exec rspec
|
|
48
|
+
|
|
49
|
+
# Run linter
|
|
50
|
+
bundle exec rubocop
|
|
51
|
+
```
|
|
52
|
+
|
|
53
|
+
### Running the CLI locally
|
|
54
|
+
|
|
55
|
+
```bash
|
|
56
|
+
# From the project root
|
|
57
|
+
bundle exec exe/fake_data_dsl --help
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
## How to Contribute
|
|
61
|
+
|
|
62
|
+
### Reporting Bugs
|
|
63
|
+
|
|
64
|
+
Before creating a bug report:
|
|
65
|
+
|
|
66
|
+
1. Check the [existing issues](https://github.com/talaatmagdyx/fake_data_dsl/issues)
|
|
67
|
+
2. Ensure you're using the latest version
|
|
68
|
+
3. Collect information about the bug:
|
|
69
|
+
- Stack trace
|
|
70
|
+
- Ruby version (`ruby --version`)
|
|
71
|
+
- Gem version (`bundle show fake_data_dsl`)
|
|
72
|
+
- Your operating system
|
|
73
|
+
- Steps to reproduce
|
|
74
|
+
|
|
75
|
+
### Suggesting Enhancements
|
|
76
|
+
|
|
77
|
+
Enhancement suggestions are tracked as GitHub issues. When creating an enhancement suggestion, include:
|
|
78
|
+
|
|
79
|
+
- A clear and descriptive title
|
|
80
|
+
- A detailed description of the proposed functionality
|
|
81
|
+
- Examples of how the feature would be used
|
|
82
|
+
- Why this enhancement would be useful
|
|
83
|
+
|
|
84
|
+
### Adding New Types
|
|
85
|
+
|
|
86
|
+
To add a new data type:
|
|
87
|
+
|
|
88
|
+
1. Create a new file in `lib/fake_data_dsl/types/` in the appropriate domain folder
|
|
89
|
+
2. Inherit from `FakeDataDSL::Types::Base`
|
|
90
|
+
3. Implement `generate_random`, `generate_edge`, and `generate_invalid` methods
|
|
91
|
+
4. Register the type in `lib/fake_data_dsl.rb` in `register_builtin_types!`
|
|
92
|
+
5. Add tests in `spec/types/`
|
|
93
|
+
6. Document in `tech_docs/dsl/core_types.md`
|
|
94
|
+
|
|
95
|
+
Example:
|
|
96
|
+
|
|
97
|
+
```ruby
|
|
98
|
+
# lib/fake_data_dsl/types/personal_names/nickname.rb
|
|
99
|
+
module FakeDataDSL
|
|
100
|
+
module Types
|
|
101
|
+
module PersonalNames
|
|
102
|
+
class Nickname < Base
|
|
103
|
+
def generate_random(rng, context, args)
|
|
104
|
+
rng.element(["Ace", "Buddy", "Chief", "Duke", "Flash"])
|
|
105
|
+
end
|
|
106
|
+
|
|
107
|
+
def generate_edge(rng, context, args)
|
|
108
|
+
rng.element(["", "X", "A" * 100])
|
|
109
|
+
end
|
|
110
|
+
|
|
111
|
+
def generate_invalid(rng, context, args)
|
|
112
|
+
rng.element([nil, 123, [], {}])
|
|
113
|
+
end
|
|
114
|
+
end
|
|
115
|
+
end
|
|
116
|
+
end
|
|
117
|
+
end
|
|
118
|
+
```
|
|
119
|
+
|
|
120
|
+
### Adding New Behaviors
|
|
121
|
+
|
|
122
|
+
To add a new behavior:
|
|
123
|
+
|
|
124
|
+
1. Create a new file in `lib/fake_data_dsl/behaviors/`
|
|
125
|
+
2. Inherit from `FakeDataDSL::Behaviors::Base`
|
|
126
|
+
3. Implement the `apply` method
|
|
127
|
+
4. Register in `lib/fake_data_dsl/behaviors/registry.rb`
|
|
128
|
+
5. Add tests and documentation
|
|
129
|
+
|
|
130
|
+
### Adding New Export Formats
|
|
131
|
+
|
|
132
|
+
To add a new export format:
|
|
133
|
+
|
|
134
|
+
1. Create a new file in `lib/fake_data_dsl/export/`
|
|
135
|
+
2. Inherit from `FakeDataDSL::Export::Base`
|
|
136
|
+
3. Implement `export` and optionally `export_all` methods
|
|
137
|
+
4. Register in `lib/fake_data_dsl/export.rb`
|
|
138
|
+
5. Add CLI support in `lib/fake_data_dsl/cli.rb` if needed
|
|
139
|
+
6. Add tests and documentation
|
|
140
|
+
|
|
141
|
+
## Pull Request Process
|
|
142
|
+
|
|
143
|
+
1. Create a new branch from `main`:
|
|
144
|
+
```bash
|
|
145
|
+
git checkout -b feature/my-new-feature
|
|
146
|
+
```
|
|
147
|
+
|
|
148
|
+
2. Make your changes and commit:
|
|
149
|
+
```bash
|
|
150
|
+
git add .
|
|
151
|
+
git commit -m "feat: add new feature X"
|
|
152
|
+
```
|
|
153
|
+
|
|
154
|
+
3. Follow the [Conventional Commits](https://www.conventionalcommits.org/) specification:
|
|
155
|
+
- `feat:` - New features
|
|
156
|
+
- `fix:` - Bug fixes
|
|
157
|
+
- `docs:` - Documentation changes
|
|
158
|
+
- `style:` - Code style changes (formatting, etc.)
|
|
159
|
+
- `refactor:` - Code refactoring
|
|
160
|
+
- `test:` - Adding or updating tests
|
|
161
|
+
- `chore:` - Maintenance tasks
|
|
162
|
+
|
|
163
|
+
4. Ensure all tests pass:
|
|
164
|
+
```bash
|
|
165
|
+
bundle exec rspec
|
|
166
|
+
```
|
|
167
|
+
|
|
168
|
+
5. Ensure code style compliance:
|
|
169
|
+
```bash
|
|
170
|
+
bundle exec rubocop
|
|
171
|
+
```
|
|
172
|
+
|
|
173
|
+
6. Update documentation if needed
|
|
174
|
+
|
|
175
|
+
7. Push your branch and create a Pull Request
|
|
176
|
+
|
|
177
|
+
### PR Requirements
|
|
178
|
+
|
|
179
|
+
- [ ] Tests pass
|
|
180
|
+
- [ ] RuboCop passes
|
|
181
|
+
- [ ] New code has test coverage
|
|
182
|
+
- [ ] Documentation updated (if applicable)
|
|
183
|
+
- [ ] CHANGELOG.md updated (for user-facing changes)
|
|
184
|
+
|
|
185
|
+
## Code Style
|
|
186
|
+
|
|
187
|
+
We follow the Ruby Style Guide with some customizations. RuboCop is configured to enforce these rules.
|
|
188
|
+
|
|
189
|
+
### Key Guidelines
|
|
190
|
+
|
|
191
|
+
- Use 2 spaces for indentation
|
|
192
|
+
- Use `frozen_string_literal` pragma
|
|
193
|
+
- Maximum line length: 120 characters
|
|
194
|
+
- Document public methods with YARD
|
|
195
|
+
- Prefer explicit over implicit
|
|
196
|
+
- Keep methods small and focused
|
|
197
|
+
|
|
198
|
+
### Example
|
|
199
|
+
|
|
200
|
+
```ruby
|
|
201
|
+
# frozen_string_literal: true
|
|
202
|
+
|
|
203
|
+
module FakeDataDSL
|
|
204
|
+
module Example
|
|
205
|
+
# Generate a random example value
|
|
206
|
+
#
|
|
207
|
+
# @param count [Integer] number of values to generate
|
|
208
|
+
# @return [Array<String>] generated values
|
|
209
|
+
#
|
|
210
|
+
# @example
|
|
211
|
+
# generate_examples(3)
|
|
212
|
+
# # => ["example1", "example2", "example3"]
|
|
213
|
+
#
|
|
214
|
+
def generate_examples(count)
|
|
215
|
+
count.times.map { |i| "example#{i + 1}" }
|
|
216
|
+
end
|
|
217
|
+
end
|
|
218
|
+
end
|
|
219
|
+
```
|
|
220
|
+
|
|
221
|
+
## Testing Guidelines
|
|
222
|
+
|
|
223
|
+
### Running Tests
|
|
224
|
+
|
|
225
|
+
```bash
|
|
226
|
+
# Run all tests
|
|
227
|
+
bundle exec rspec
|
|
228
|
+
|
|
229
|
+
# Run specific file
|
|
230
|
+
bundle exec rspec spec/types/core_types_spec.rb
|
|
231
|
+
|
|
232
|
+
# Run with coverage
|
|
233
|
+
bundle exec rspec --coverage
|
|
234
|
+
```
|
|
235
|
+
|
|
236
|
+
### Writing Tests
|
|
237
|
+
|
|
238
|
+
- Place tests in `spec/` mirroring the `lib/` structure
|
|
239
|
+
- Use descriptive `describe` and `it` blocks
|
|
240
|
+
- Test edge cases and error conditions
|
|
241
|
+
- Use factories or fixtures for complex data
|
|
242
|
+
|
|
243
|
+
### Example Test
|
|
244
|
+
|
|
245
|
+
```ruby
|
|
246
|
+
# frozen_string_literal: true
|
|
247
|
+
|
|
248
|
+
RSpec.describe FakeDataDSL::Types::PersonalNames::Nickname do
|
|
249
|
+
subject(:generator) { described_class.new }
|
|
250
|
+
|
|
251
|
+
describe "#generate_random" do
|
|
252
|
+
it "returns a string" do
|
|
253
|
+
result = generator.generate_random(rng, context, {})
|
|
254
|
+
expect(result).to be_a(String)
|
|
255
|
+
end
|
|
256
|
+
|
|
257
|
+
it "returns consistent results with same seed" do
|
|
258
|
+
rng1 = FakeDataDSL::Generator::RNG.new(42)
|
|
259
|
+
rng2 = FakeDataDSL::Generator::RNG.new(42)
|
|
260
|
+
|
|
261
|
+
result1 = generator.generate_random(rng1, context, {})
|
|
262
|
+
result2 = generator.generate_random(rng2, context, {})
|
|
263
|
+
|
|
264
|
+
expect(result1).to eq(result2)
|
|
265
|
+
end
|
|
266
|
+
end
|
|
267
|
+
|
|
268
|
+
describe "#generate_edge" do
|
|
269
|
+
it "returns edge case values" do
|
|
270
|
+
result = generator.generate_edge(rng, context, {})
|
|
271
|
+
expect(result).to satisfy { |v| v.empty? || v.length == 1 || v.length >= 100 }
|
|
272
|
+
end
|
|
273
|
+
end
|
|
274
|
+
end
|
|
275
|
+
```
|
|
276
|
+
|
|
277
|
+
## Documentation
|
|
278
|
+
|
|
279
|
+
### Code Documentation
|
|
280
|
+
|
|
281
|
+
- Use YARD for API documentation
|
|
282
|
+
- Document all public methods
|
|
283
|
+
- Include usage examples
|
|
284
|
+
- Document parameters and return values
|
|
285
|
+
|
|
286
|
+
### User Documentation
|
|
287
|
+
|
|
288
|
+
- Update `tech_docs/` for user-facing features
|
|
289
|
+
- Include examples that users can copy/paste
|
|
290
|
+
- Keep tutorials up to date
|
|
291
|
+
|
|
292
|
+
### Generating Docs
|
|
293
|
+
|
|
294
|
+
```bash
|
|
295
|
+
# Generate YARD documentation
|
|
296
|
+
bundle exec yard doc
|
|
297
|
+
```
|
|
298
|
+
|
|
299
|
+
## Questions?
|
|
300
|
+
|
|
301
|
+
If you have questions about contributing:
|
|
302
|
+
|
|
303
|
+
1. Check existing documentation
|
|
304
|
+
2. Search existing issues
|
|
305
|
+
3. Open a new issue with the "question" label
|
|
306
|
+
|
|
307
|
+
Thank you for contributing to FakeDataDSL! 🎉
|
data/DOCUMENTATION.md
ADDED
|
@@ -0,0 +1,204 @@
|
|
|
1
|
+
# Documentation Guide
|
|
2
|
+
|
|
3
|
+
This guide explains how to generate and view the documentation for FakeDataDSL.
|
|
4
|
+
|
|
5
|
+
## Prerequisites
|
|
6
|
+
|
|
7
|
+
First, install the documentation dependencies:
|
|
8
|
+
|
|
9
|
+
```bash
|
|
10
|
+
bundle install
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
This will install:
|
|
14
|
+
- `yard` - YARD documentation generator
|
|
15
|
+
- `redcarpet` - Markdown processor for YARD
|
|
16
|
+
- `webrick` - Web server for viewing docs
|
|
17
|
+
|
|
18
|
+
## Generating Documentation
|
|
19
|
+
|
|
20
|
+
### Method 1: Using Rake (Recommended)
|
|
21
|
+
|
|
22
|
+
```bash
|
|
23
|
+
# Generate documentation
|
|
24
|
+
bundle exec rake docs
|
|
25
|
+
|
|
26
|
+
# This will:
|
|
27
|
+
# - Generate HTML documentation in the doc/ directory
|
|
28
|
+
# - Include README, CHANGELOG, and all code documentation
|
|
29
|
+
# - Show a message with the location
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
After generation, open `doc/index.html` in your browser.
|
|
33
|
+
|
|
34
|
+
### Method 2: Using YARD Directly
|
|
35
|
+
|
|
36
|
+
```bash
|
|
37
|
+
# Generate documentation
|
|
38
|
+
bundle exec yard doc
|
|
39
|
+
|
|
40
|
+
# Generate with specific options
|
|
41
|
+
bundle exec yard doc --no-cache --private
|
|
42
|
+
```
|
|
43
|
+
|
|
44
|
+
### Method 3: View Documentation Online
|
|
45
|
+
|
|
46
|
+
If the gem is published to RubyGems, documentation is automatically available at:
|
|
47
|
+
- [RubyDoc.info](https://www.rubydoc.info/gems/fake_data_dsl)
|
|
48
|
+
- [RubyGems.org](https://rubygems.org/gems/fake_data_dsl)
|
|
49
|
+
|
|
50
|
+
## Viewing Documentation Locally
|
|
51
|
+
|
|
52
|
+
### Option 1: Open HTML Files
|
|
53
|
+
|
|
54
|
+
After generating docs:
|
|
55
|
+
|
|
56
|
+
```bash
|
|
57
|
+
# macOS
|
|
58
|
+
open doc/index.html
|
|
59
|
+
|
|
60
|
+
# Linux
|
|
61
|
+
xdg-open doc/index.html
|
|
62
|
+
|
|
63
|
+
# Windows
|
|
64
|
+
start doc/index.html
|
|
65
|
+
```
|
|
66
|
+
|
|
67
|
+
### Option 2: YARD Server (Live Reload)
|
|
68
|
+
|
|
69
|
+
Start a local documentation server with auto-reload:
|
|
70
|
+
|
|
71
|
+
```bash
|
|
72
|
+
# Using Rake
|
|
73
|
+
bundle exec rake docs_server
|
|
74
|
+
|
|
75
|
+
# Or directly
|
|
76
|
+
bundle exec yard server --reload
|
|
77
|
+
```
|
|
78
|
+
|
|
79
|
+
Then open http://localhost:8808 in your browser.
|
|
80
|
+
|
|
81
|
+
The server will automatically reload when you make changes to the code.
|
|
82
|
+
|
|
83
|
+
## Documentation Structure
|
|
84
|
+
|
|
85
|
+
The generated documentation includes:
|
|
86
|
+
|
|
87
|
+
- **README.md** - Full project documentation and usage guide
|
|
88
|
+
- **API Reference** - All classes, modules, and methods
|
|
89
|
+
- **Examples** - Code examples from YARD comments
|
|
90
|
+
- **Type System** - All built-in types with descriptions
|
|
91
|
+
- **Behaviors** - All simulation behaviors
|
|
92
|
+
- **Configuration** - Configuration options
|
|
93
|
+
- **Error Classes** - All error types
|
|
94
|
+
|
|
95
|
+
## Writing Documentation
|
|
96
|
+
|
|
97
|
+
### YARD Comments
|
|
98
|
+
|
|
99
|
+
All public methods should have YARD documentation:
|
|
100
|
+
|
|
101
|
+
```ruby
|
|
102
|
+
# Generates a UUID value.
|
|
103
|
+
#
|
|
104
|
+
# Supports UUID versions 4, 6, and 7 for different use cases.
|
|
105
|
+
# Version 4 is random, version 6/7 are time-sortable.
|
|
106
|
+
#
|
|
107
|
+
# @param rng [Generator::RNG] random number generator
|
|
108
|
+
# @param args [Hash] generation arguments
|
|
109
|
+
# @option args [Integer] :version UUID version (4, 6, or 7)
|
|
110
|
+
# @return [String] UUID string in standard format
|
|
111
|
+
#
|
|
112
|
+
# @example Generate UUID v4
|
|
113
|
+
# uuid = type.generate_random(rng, {})
|
|
114
|
+
# # => "550e8400-e29b-41d4-a716-446655440000"
|
|
115
|
+
#
|
|
116
|
+
# @see https://www.rfc-editor.org/rfc/rfc9562 RFC 9562 - UUID
|
|
117
|
+
#
|
|
118
|
+
def generate_random(rng, args)
|
|
119
|
+
# Implementation
|
|
120
|
+
end
|
|
121
|
+
```
|
|
122
|
+
|
|
123
|
+
### Documentation Tags
|
|
124
|
+
|
|
125
|
+
Common YARD tags:
|
|
126
|
+
|
|
127
|
+
- `@param` - Method parameters
|
|
128
|
+
- `@return` - Return value
|
|
129
|
+
- `@option` - Hash options
|
|
130
|
+
- `@example` - Usage examples
|
|
131
|
+
- `@raise` - Exceptions raised
|
|
132
|
+
- `@see` - Related references
|
|
133
|
+
- `@since` - Version introduced
|
|
134
|
+
- `@deprecated` - Deprecated methods
|
|
135
|
+
- `@api` - API visibility (public/private)
|
|
136
|
+
|
|
137
|
+
## Updating Documentation
|
|
138
|
+
|
|
139
|
+
After making code changes:
|
|
140
|
+
|
|
141
|
+
1. Update YARD comments in code
|
|
142
|
+
2. Regenerate documentation: `bundle exec rake docs`
|
|
143
|
+
3. Review changes in `doc/index.html`
|
|
144
|
+
4. Commit documentation updates with code changes
|
|
145
|
+
|
|
146
|
+
## Documentation Files
|
|
147
|
+
|
|
148
|
+
- **README.md** - Main project documentation
|
|
149
|
+
- **CHANGELOG.md** - Version history
|
|
150
|
+
- **CONTRIBUTING.md** - Contribution guidelines
|
|
151
|
+
- **CODE_OF_CONDUCT.md** - Community standards
|
|
152
|
+
- **DOCUMENTATION.md** - This file
|
|
153
|
+
- **.yardopts** - YARD configuration
|
|
154
|
+
|
|
155
|
+
## Troubleshooting
|
|
156
|
+
|
|
157
|
+
### Documentation Not Generating
|
|
158
|
+
|
|
159
|
+
```bash
|
|
160
|
+
# Check if YARD is installed
|
|
161
|
+
bundle exec yard --version
|
|
162
|
+
|
|
163
|
+
# Clear YARD cache
|
|
164
|
+
rm -rf .yardoc doc/
|
|
165
|
+
|
|
166
|
+
# Regenerate
|
|
167
|
+
bundle exec rake docs
|
|
168
|
+
```
|
|
169
|
+
|
|
170
|
+
### Missing Examples
|
|
171
|
+
|
|
172
|
+
Ensure examples in YARD comments use the `@example` tag:
|
|
173
|
+
|
|
174
|
+
```ruby
|
|
175
|
+
# @example Basic usage
|
|
176
|
+
# schema = FakeDataDSL.load('user.dsl')
|
|
177
|
+
# user = schema.generate
|
|
178
|
+
```
|
|
179
|
+
|
|
180
|
+
### Private Methods Not Showing
|
|
181
|
+
|
|
182
|
+
By default, private methods are hidden. To include them:
|
|
183
|
+
|
|
184
|
+
```bash
|
|
185
|
+
bundle exec yard doc --private
|
|
186
|
+
```
|
|
187
|
+
|
|
188
|
+
Or update `.yardopts` to include `--private`.
|
|
189
|
+
|
|
190
|
+
## Publishing Documentation
|
|
191
|
+
|
|
192
|
+
When releasing a new version:
|
|
193
|
+
|
|
194
|
+
1. Generate documentation: `bundle exec rake docs`
|
|
195
|
+
2. Commit the `doc/` directory (if hosting yourself)
|
|
196
|
+
3. Push to RubyGems (auto-publishes to RubyDoc.info)
|
|
197
|
+
4. Update any external documentation sites
|
|
198
|
+
|
|
199
|
+
## Additional Resources
|
|
200
|
+
|
|
201
|
+
- [YARD Documentation](https://yardoc.org/)
|
|
202
|
+
- [YARD Tags Reference](https://www.rubydoc.info/gems/yard/file/docs/Tags.md)
|
|
203
|
+
- [RubyDoc.info](https://www.rubydoc.info/)
|
|
204
|
+
|
|
@@ -0,0 +1,194 @@
|
|
|
1
|
+
# FakeDataDSL Documentation Guide
|
|
2
|
+
|
|
3
|
+
## 📚 Documentation Structure
|
|
4
|
+
|
|
5
|
+
The FakeDataDSL documentation consists of:
|
|
6
|
+
|
|
7
|
+
1. **YARD Documentation** - Auto-generated from code comments
|
|
8
|
+
2. **Markdown Guides** - Comprehensive guides in `docs/` folder
|
|
9
|
+
3. **API Reference** - Programmatic API documentation
|
|
10
|
+
|
|
11
|
+
## 🚀 Quick Start
|
|
12
|
+
|
|
13
|
+
### Generate Documentation
|
|
14
|
+
|
|
15
|
+
```bash
|
|
16
|
+
# Navigate to project directory
|
|
17
|
+
cd /path/to/fake_data_dsl
|
|
18
|
+
|
|
19
|
+
# Generate YARD documentation
|
|
20
|
+
bundle exec yard doc
|
|
21
|
+
```
|
|
22
|
+
|
|
23
|
+
### View Documentation
|
|
24
|
+
|
|
25
|
+
```bash
|
|
26
|
+
# Open in browser (macOS)
|
|
27
|
+
open doc/index.html
|
|
28
|
+
|
|
29
|
+
# Open in browser (Linux)
|
|
30
|
+
xdg-open doc/index.html
|
|
31
|
+
|
|
32
|
+
# Or use a local server
|
|
33
|
+
cd doc
|
|
34
|
+
python3 -m http.server 8000
|
|
35
|
+
# Visit http://localhost:8000
|
|
36
|
+
```
|
|
37
|
+
|
|
38
|
+
## 📖 Documentation Files
|
|
39
|
+
|
|
40
|
+
All documentation is in the `docs/` folder:
|
|
41
|
+
|
|
42
|
+
- **README.md** - Documentation index
|
|
43
|
+
- **getting_started.md** - Quick start guide
|
|
44
|
+
- **dsl_reference.md** - Complete DSL syntax
|
|
45
|
+
- **type_reference.md** - All available types
|
|
46
|
+
- **behaviors.md** - Behaviors guide
|
|
47
|
+
- **generation_modes.md** - Generation modes
|
|
48
|
+
- **advanced_features.md** - Advanced features
|
|
49
|
+
- **examples.md** - Real-world examples
|
|
50
|
+
- **api_reference.md** - Programmatic API
|
|
51
|
+
- **best_practices.md** - Best practices
|
|
52
|
+
- **troubleshooting.md** - Common issues
|
|
53
|
+
- **HOW_TO_GENERATE_DOCS.md** - This guide
|
|
54
|
+
- **QUICK_REFERENCE.md** - Quick reference card
|
|
55
|
+
|
|
56
|
+
## 🔧 Configuration
|
|
57
|
+
|
|
58
|
+
The `.yardopts` file configures YARD:
|
|
59
|
+
|
|
60
|
+
- Includes markdown files from `docs/`
|
|
61
|
+
- Sets output directory to `doc/`
|
|
62
|
+
- Configures markup provider (Redcarpet)
|
|
63
|
+
|
|
64
|
+
## 📝 Adding Documentation
|
|
65
|
+
|
|
66
|
+
### Add New Guide
|
|
67
|
+
|
|
68
|
+
1. Create markdown file in `docs/`:
|
|
69
|
+
```bash
|
|
70
|
+
touch docs/my_guide.md
|
|
71
|
+
```
|
|
72
|
+
|
|
73
|
+
2. Add to `docs/README.md` table of contents
|
|
74
|
+
|
|
75
|
+
3. Regenerate docs:
|
|
76
|
+
```bash
|
|
77
|
+
bundle exec yard doc
|
|
78
|
+
```
|
|
79
|
+
|
|
80
|
+
### Update Code Documentation
|
|
81
|
+
|
|
82
|
+
1. Add YARD comments to code:
|
|
83
|
+
```ruby
|
|
84
|
+
# My method
|
|
85
|
+
#
|
|
86
|
+
# @param arg [String] description
|
|
87
|
+
# @return [Integer] description
|
|
88
|
+
#
|
|
89
|
+
def my_method(arg)
|
|
90
|
+
# ...
|
|
91
|
+
end
|
|
92
|
+
```
|
|
93
|
+
|
|
94
|
+
2. Regenerate docs:
|
|
95
|
+
```bash
|
|
96
|
+
bundle exec yard doc
|
|
97
|
+
```
|
|
98
|
+
|
|
99
|
+
## 🌐 Publishing
|
|
100
|
+
|
|
101
|
+
### GitHub Pages
|
|
102
|
+
|
|
103
|
+
1. Generate docs:
|
|
104
|
+
```bash
|
|
105
|
+
bundle exec yard doc
|
|
106
|
+
```
|
|
107
|
+
|
|
108
|
+
2. Push to `gh-pages` branch:
|
|
109
|
+
```bash
|
|
110
|
+
git checkout --orphan gh-pages
|
|
111
|
+
git rm -rf .
|
|
112
|
+
cp -r doc/* .
|
|
113
|
+
git add .
|
|
114
|
+
git commit -m "Update documentation"
|
|
115
|
+
git push origin gh-pages
|
|
116
|
+
```
|
|
117
|
+
|
|
118
|
+
3. Enable GitHub Pages in repository settings
|
|
119
|
+
|
|
120
|
+
## 📊 Documentation Stats
|
|
121
|
+
|
|
122
|
+
Current documentation coverage:
|
|
123
|
+
- **94.37% documented**
|
|
124
|
+
- 154 classes (0 undocumented)
|
|
125
|
+
- 588 methods (9 undocumented)
|
|
126
|
+
- 99 constants (36 undocumented)
|
|
127
|
+
|
|
128
|
+
## 🔍 Accessing Documentation
|
|
129
|
+
|
|
130
|
+
### Local Access
|
|
131
|
+
|
|
132
|
+
```bash
|
|
133
|
+
# Generate
|
|
134
|
+
bundle exec yard doc
|
|
135
|
+
|
|
136
|
+
# View
|
|
137
|
+
open doc/index.html
|
|
138
|
+
```
|
|
139
|
+
|
|
140
|
+
### Online Access
|
|
141
|
+
|
|
142
|
+
If published to GitHub Pages:
|
|
143
|
+
- Visit: `https://yourusername.github.io/fake_data_dsl/`
|
|
144
|
+
|
|
145
|
+
## 📚 Documentation Sections
|
|
146
|
+
|
|
147
|
+
### For Users
|
|
148
|
+
|
|
149
|
+
- [Getting Started](docs/getting_started.md)
|
|
150
|
+
- [DSL Reference](docs/dsl_reference.md)
|
|
151
|
+
- [Type Reference](docs/type_reference.md)
|
|
152
|
+
- [Examples](docs/examples.md)
|
|
153
|
+
|
|
154
|
+
### For Developers
|
|
155
|
+
|
|
156
|
+
- [API Reference](docs/api_reference.md)
|
|
157
|
+
- [Advanced Features](docs/advanced_features.md)
|
|
158
|
+
- [Best Practices](docs/best_practices.md)
|
|
159
|
+
|
|
160
|
+
### For Troubleshooting
|
|
161
|
+
|
|
162
|
+
- [Troubleshooting](docs/troubleshooting.md)
|
|
163
|
+
- [Best Practices](docs/best_practices.md)
|
|
164
|
+
|
|
165
|
+
## 🛠️ Troubleshooting
|
|
166
|
+
|
|
167
|
+
### YARD Not Found
|
|
168
|
+
|
|
169
|
+
```bash
|
|
170
|
+
gem install yard
|
|
171
|
+
# or
|
|
172
|
+
bundle install
|
|
173
|
+
```
|
|
174
|
+
|
|
175
|
+
### Documentation Not Updating
|
|
176
|
+
|
|
177
|
+
```bash
|
|
178
|
+
rm -rf .yardoc doc/
|
|
179
|
+
bundle exec yard doc
|
|
180
|
+
```
|
|
181
|
+
|
|
182
|
+
### Missing Markdown Files
|
|
183
|
+
|
|
184
|
+
Ensure `.yardopts` includes:
|
|
185
|
+
```
|
|
186
|
+
docs/**/*.md
|
|
187
|
+
```
|
|
188
|
+
|
|
189
|
+
## 📞 Need Help?
|
|
190
|
+
|
|
191
|
+
- Check [Troubleshooting](docs/troubleshooting.md)
|
|
192
|
+
- Review [Examples](docs/examples.md)
|
|
193
|
+
- Open an issue on GitHub
|
|
194
|
+
|
data/LICENSE
ADDED
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2024 Synthra Team
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
|
22
|
+
|