add: adding support for creating examples and templates
This commit is contained in:
parent
204b1b998e
commit
245321849a
50 changed files with 218 additions and 0 deletions
0
examples/app-template/.editorconfig
Normal file
0
examples/app-template/.editorconfig
Normal file
0
examples/app-template/.env.example.yaml
Normal file
0
examples/app-template/.env.example.yaml
Normal file
0
examples/app-template/.gitattributes
vendored
Normal file
0
examples/app-template/.gitattributes
vendored
Normal file
25
examples/app-template/.gitignore
vendored
Normal file
25
examples/app-template/.gitignore
vendored
Normal file
|
@ -0,0 +1,25 @@
|
||||||
|
# See https://www.dartlang.org/guides/libraries/private-files
|
||||||
|
|
||||||
|
# Files and directories created by pub
|
||||||
|
.dart_tool/
|
||||||
|
.packages
|
||||||
|
build/
|
||||||
|
# If you're building an application, you may want to check-in your pubspec.lock
|
||||||
|
pubspec.lock
|
||||||
|
|
||||||
|
# Ignore autosave files
|
||||||
|
README.md~
|
||||||
|
.gitignore~
|
||||||
|
|
||||||
|
# Directory created by dartdoc
|
||||||
|
# If you don't generate documentation locally you can remove this line.
|
||||||
|
doc/api/
|
||||||
|
|
||||||
|
# Avoid committing generated Javascript files:
|
||||||
|
*.dart.js
|
||||||
|
*.info.json # Produced by the --dump-info flag.
|
||||||
|
*.js # When generated by dart2js. Don't specify *.js if your
|
||||||
|
# project includes source files written in JavaScript.
|
||||||
|
*.js_
|
||||||
|
*.js.deps
|
||||||
|
*.js.map
|
3
examples/app-template/CHANGELOG.md
Normal file
3
examples/app-template/CHANGELOG.md
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
## 1.0.0
|
||||||
|
|
||||||
|
- Initial version.
|
22
examples/app-template/LICENSE
Normal file
22
examples/app-template/LICENSE
Normal file
|
@ -0,0 +1,22 @@
|
||||||
|
|
||||||
|
The MIT License (MIT)
|
||||||
|
|
||||||
|
Copyright (c) 2024 Patrick Stewart
|
||||||
|
|
||||||
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||||
|
of this software and associated documentation files (the "Software"), to deal
|
||||||
|
in the Software without restriction, including without limitation the rights
|
||||||
|
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||||
|
copies of the Software, and to permit persons to whom the Software is
|
||||||
|
furnished to do so, subject to the following conditions:
|
||||||
|
|
||||||
|
The above copyright notice and this permission notice shall be included in all
|
||||||
|
copies or substantial portions of the Software.
|
||||||
|
|
||||||
|
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||||
|
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||||
|
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||||
|
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||||
|
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||||
|
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||||
|
SOFTWARE.
|
42
examples/app-template/README.md
Normal file
42
examples/app-template/README.md
Normal file
|
@ -0,0 +1,42 @@
|
||||||
|
<p align="center"><a href="https://laravel.com" target="_blank"><img src="https://raw.githubusercontent.com/protevus/branding/main/protevus-logo-bg.png"></a></p>
|
||||||
|
|
||||||
|
## About Protevus
|
||||||
|
|
||||||
|
> **Note:** This repository provides a base application setup inspired by Laravel. If you want to contribute to the core Protevus Platform, visit the main [Protevus Platform repository](https://github.com/protevus/platform).
|
||||||
|
|
||||||
|
Protevus is a reference implementation that demonstrates how to build applications using the Protevus Platform. It serves as a starting point for developers to create their own applications leveraging the power and versatility of the Protevus Platform.
|
||||||
|
|
||||||
|
## Features
|
||||||
|
|
||||||
|
- **Laravel-inspired Structure**: The starter application follows a structure and conventions inspired by the Laravel framework, making it familiar to Laravel developers.
|
||||||
|
- **Protevus Platform Integration**: The application is built on top of the Protevus Platform, providing a Laravel-compatible API and development experience.
|
||||||
|
- **Example Components**: The repository includes example components such as controllers, middleware, and services, showcasing best practices and usage patterns.
|
||||||
|
- **Extensibility**: Developers can easily extend and customize the starter application to meet their specific project requirements.
|
||||||
|
|
||||||
|
## Getting Started
|
||||||
|
|
||||||
|
To get started with the Protevus Starter Application, follow these steps:
|
||||||
|
|
||||||
|
1. **Install Dependencies**: Ensure you have the Dart SDK and the necessary dependencies installed on your system.
|
||||||
|
2. **Clone the Repository**: Clone the Protevus Starter Application repository to your local machine.
|
||||||
|
3. **Build and Run**: Follow the instructions in the repository's documentation to build and run the application.
|
||||||
|
|
||||||
|
## Documentation
|
||||||
|
|
||||||
|
Documentation for the Protevus Starter Application is available at [protevus.com/docs/protevus](https://protevus.com/docs/protevus). The documentation covers installation, configuration, customization, and deployment guides.
|
||||||
|
|
||||||
|
## Contributing
|
||||||
|
|
||||||
|
We welcome contributions from the community! If you'd like to contribute to the Protevus Starter Application, please follow the guidelines outlined in the [CONTRIBUTING.md](CONTRIBUTING.md) file.
|
||||||
|
|
||||||
|
## License
|
||||||
|
|
||||||
|
The Protevus Application is released under the [MIT License](LICENSE).
|
||||||
|
|
||||||
|
## Support and Community
|
||||||
|
|
||||||
|
If you have any questions, issues, or suggestions, please join our community:
|
||||||
|
|
||||||
|
- **GitHub Discussions**: [github.com/protevus/protevus/discussions](https://github.com/protevus/protevus/discussions)
|
||||||
|
- **Twitter**: [@Protevus](https://twitter.com/Protevus)
|
||||||
|
|
30
examples/app-template/analysis_options.yaml
Normal file
30
examples/app-template/analysis_options.yaml
Normal file
|
@ -0,0 +1,30 @@
|
||||||
|
# This file configures the static analysis results for your project (errors,
|
||||||
|
# warnings, and lints).
|
||||||
|
#
|
||||||
|
# This enables the 'recommended' set of lints from `package:lints`.
|
||||||
|
# This set helps identify many issues that may lead to problems when running
|
||||||
|
# or consuming Dart code, and enforces writing Dart using a single, idiomatic
|
||||||
|
# style and format.
|
||||||
|
#
|
||||||
|
# If you want a smaller set of lints you can change this to specify
|
||||||
|
# 'package:lints/core.yaml'. These are just the most critical lints
|
||||||
|
# (the recommended set includes the core lints).
|
||||||
|
# The core lints are also what is used by pub.dev for scoring packages.
|
||||||
|
|
||||||
|
include: package:lints/recommended.yaml
|
||||||
|
|
||||||
|
# Uncomment the following section to specify additional rules.
|
||||||
|
|
||||||
|
# linter:
|
||||||
|
# rules:
|
||||||
|
# - camel_case_types
|
||||||
|
|
||||||
|
# analyzer:
|
||||||
|
# exclude:
|
||||||
|
# - path/to/excluded/files/**
|
||||||
|
|
||||||
|
# For more information about the core and recommended set of lints, see
|
||||||
|
# https://dart.dev/go/core-lints
|
||||||
|
|
||||||
|
# For additional information about configuring this file, see
|
||||||
|
# https://dart.dev/guides/language/analysis-options
|
0
examples/app-template/app/models/user.dart
Normal file
0
examples/app-template/app/models/user.dart
Normal file
0
examples/app-template/bootstrap/app.dart
Normal file
0
examples/app-template/bootstrap/app.dart
Normal file
0
examples/app-template/bootstrap/cache/.gitkeep
vendored
Normal file
0
examples/app-template/bootstrap/cache/.gitkeep
vendored
Normal file
0
examples/app-template/bootstrap/providers.dart
Normal file
0
examples/app-template/bootstrap/providers.dart
Normal file
0
examples/app-template/caden.dart
Normal file
0
examples/app-template/caden.dart
Normal file
0
examples/app-template/config/app.dart
Normal file
0
examples/app-template/config/app.dart
Normal file
0
examples/app-template/config/auth.dart
Normal file
0
examples/app-template/config/auth.dart
Normal file
0
examples/app-template/config/cache.dart
Normal file
0
examples/app-template/config/cache.dart
Normal file
0
examples/app-template/config/database.dart
Normal file
0
examples/app-template/config/database.dart
Normal file
0
examples/app-template/config/filesystems.dart
Normal file
0
examples/app-template/config/filesystems.dart
Normal file
0
examples/app-template/config/logging.dart
Normal file
0
examples/app-template/config/logging.dart
Normal file
0
examples/app-template/config/mail.dart
Normal file
0
examples/app-template/config/mail.dart
Normal file
0
examples/app-template/config/queue.dart
Normal file
0
examples/app-template/config/queue.dart
Normal file
0
examples/app-template/config/services.dart
Normal file
0
examples/app-template/config/services.dart
Normal file
0
examples/app-template/config/session.dart
Normal file
0
examples/app-template/config/session.dart
Normal file
14
examples/app-template/devbox.json
Normal file
14
examples/app-template/devbox.json
Normal file
|
@ -0,0 +1,14 @@
|
||||||
|
{
|
||||||
|
"$schema": "https://raw.githubusercontent.com/jetify-com/devbox/0.11.0/.schema/devbox.schema.json",
|
||||||
|
"packages": ["dart@latest"],
|
||||||
|
"shell": {
|
||||||
|
"init_hook": [
|
||||||
|
"echo 'Welcome to devbox!' > /dev/null"
|
||||||
|
],
|
||||||
|
"scripts": {
|
||||||
|
"test": [
|
||||||
|
"echo \"Error: no test specified\" && exit 1"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
53
examples/app-template/devbox.lock
Normal file
53
examples/app-template/devbox.lock
Normal file
|
@ -0,0 +1,53 @@
|
||||||
|
{
|
||||||
|
"lockfile_version": "1",
|
||||||
|
"packages": {
|
||||||
|
"dart@latest": {
|
||||||
|
"last_modified": "2024-06-03T07:19:07Z",
|
||||||
|
"resolved": "github:NixOS/nixpkgs/4a4ecb0ab415c9fccfb005567a215e6a9564cdf5#dart",
|
||||||
|
"source": "devbox-search",
|
||||||
|
"version": "3.4.2",
|
||||||
|
"systems": {
|
||||||
|
"aarch64-darwin": {
|
||||||
|
"outputs": [
|
||||||
|
{
|
||||||
|
"name": "out",
|
||||||
|
"path": "/nix/store/9piqr817cdsgmz31m8q723lxhcpgqsa4-dart-3.4.2",
|
||||||
|
"default": true
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"store_path": "/nix/store/9piqr817cdsgmz31m8q723lxhcpgqsa4-dart-3.4.2"
|
||||||
|
},
|
||||||
|
"aarch64-linux": {
|
||||||
|
"outputs": [
|
||||||
|
{
|
||||||
|
"name": "out",
|
||||||
|
"path": "/nix/store/1j3h5yqxvgzakv5gir1ssg7wggwxhmsd-dart-3.4.2",
|
||||||
|
"default": true
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"store_path": "/nix/store/1j3h5yqxvgzakv5gir1ssg7wggwxhmsd-dart-3.4.2"
|
||||||
|
},
|
||||||
|
"x86_64-darwin": {
|
||||||
|
"outputs": [
|
||||||
|
{
|
||||||
|
"name": "out",
|
||||||
|
"path": "/nix/store/k8a6gkss3s19p5dhbzgbdqqk5b8qzd7d-dart-3.4.2",
|
||||||
|
"default": true
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"store_path": "/nix/store/k8a6gkss3s19p5dhbzgbdqqk5b8qzd7d-dart-3.4.2"
|
||||||
|
},
|
||||||
|
"x86_64-linux": {
|
||||||
|
"outputs": [
|
||||||
|
{
|
||||||
|
"name": "out",
|
||||||
|
"path": "/nix/store/wbj1csi5fk2w99aiglwgg1mv406pw4pn-dart-3.4.2",
|
||||||
|
"default": true
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"store_path": "/nix/store/wbj1csi5fk2w99aiglwgg1mv406pw4pn-dart-3.4.2"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
0
examples/app-template/public/index.dart
Normal file
0
examples/app-template/public/index.dart
Normal file
28
examples/app-template/pubspec.yaml
Normal file
28
examples/app-template/pubspec.yaml
Normal file
|
@ -0,0 +1,28 @@
|
||||||
|
name: app-template
|
||||||
|
description: An absolute bare-bones protevus app.
|
||||||
|
version: 1.0.0
|
||||||
|
# repository: https://github.com/my_org/my_repo
|
||||||
|
|
||||||
|
environment:
|
||||||
|
sdk: ^3.4.0
|
||||||
|
|
||||||
|
# Add regular dependencies here.
|
||||||
|
dependencies:
|
||||||
|
web: ^0.5.1
|
||||||
|
|
||||||
|
dev_dependencies:
|
||||||
|
build_runner: ^2.4.8
|
||||||
|
build_web_compilers: ^4.0.9
|
||||||
|
lints: ^3.0.0
|
||||||
|
|
||||||
|
# Override default source directory
|
||||||
|
source_directories:
|
||||||
|
- app
|
||||||
|
- bootstrap
|
||||||
|
- config
|
||||||
|
- database
|
||||||
|
- public
|
||||||
|
- resources
|
||||||
|
- routes
|
||||||
|
- storage
|
||||||
|
- tests
|
0
examples/app-template/resource/css/.gitkeep
Normal file
0
examples/app-template/resource/css/.gitkeep
Normal file
0
examples/app-template/resource/js/.gitkeep
Normal file
0
examples/app-template/resource/js/.gitkeep
Normal file
0
examples/app-template/resource/views/welcome.blade.dart
Normal file
0
examples/app-template/resource/views/welcome.blade.dart
Normal file
0
examples/app-template/routes/console.dart
Normal file
0
examples/app-template/routes/console.dart
Normal file
0
examples/app-template/routes/web.dart
Normal file
0
examples/app-template/routes/web.dart
Normal file
0
examples/app-template/storage/.gitkeep
Normal file
0
examples/app-template/storage/.gitkeep
Normal file
0
examples/app-template/storage/app/.gitkeep
Normal file
0
examples/app-template/storage/app/.gitkeep
Normal file
0
examples/app-template/storage/app/public/.gitkeep
Normal file
0
examples/app-template/storage/app/public/.gitkeep
Normal file
0
examples/app-template/storage/framework/cache/.gitkeep
vendored
Normal file
0
examples/app-template/storage/framework/cache/.gitkeep
vendored
Normal file
0
examples/app-template/storage/framework/cache/data/.gitkeep
vendored
Normal file
0
examples/app-template/storage/framework/cache/data/.gitkeep
vendored
Normal file
0
examples/app-template/storage/framework/testing/.gitkeep
Normal file
0
examples/app-template/storage/framework/testing/.gitkeep
Normal file
0
examples/app-template/storage/framework/views/.gitkeep
Normal file
0
examples/app-template/storage/framework/views/.gitkeep
Normal file
0
examples/app-template/test/.gitkeep
Normal file
0
examples/app-template/test/.gitkeep
Normal file
|
@ -2,6 +2,7 @@ name: protevus_platform
|
||||||
repository: https://github.com/protevus/platform
|
repository: https://github.com/protevus/platform
|
||||||
packages:
|
packages:
|
||||||
- packages/**
|
- packages/**
|
||||||
|
- examples/**
|
||||||
|
|
||||||
command:
|
command:
|
||||||
version:
|
version:
|
||||||
|
|
Loading…
Reference in a new issue