https://github.com/preaction/yancy
The Best Web Framework Deserves the Best Content Management System
https://github.com/preaction/yancy
cms mojolicious perl web
Last synced: about 1 year ago
JSON representation
The Best Web Framework Deserves the Best Content Management System
- Host: GitHub
- URL: https://github.com/preaction/yancy
- Owner: preaction
- License: other
- Created: 2017-11-14T22:45:43.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2023-06-01T19:32:12.000Z (almost 3 years ago)
- Last Synced: 2024-06-18T15:22:32.738Z (almost 2 years ago)
- Topics: cms, mojolicious, perl, web
- Language: Perl
- Homepage: http://preaction.me/yancy/
- Size: 4.75 MB
- Stars: 54
- Watchers: 6
- Forks: 21
- Open Issues: 21
-
Metadata Files:
- Readme: README.mkdn
- Changelog: CHANGES
- Contributing: CONTRIBUTING.md
- License: LICENSE
Awesome Lists containing this project
README
# NAME
Yancy - The Best Web Framework Deserves the Best CMS
# VERSION
version 1.088
# DESCRIPTION
Yancy is a simple content management system (CMS) for the [Mojolicious](https://metacpan.org/pod/Mojolicious) web framework.
Get started with [the Yancy documentation](https://metacpan.org/pod/Yancy::Guides)!
This file documents the application base class. You can use this class directly
via the `yancy` command, or you can extend this class to build your own app.
# Starting Your Own Yancy Application
If you have an existing [Mojolicious](https://metacpan.org/pod/Mojolicious) application you want to add Yancy
to, see [Mojolicious::Plugin::Yancy](https://metacpan.org/pod/Mojolicious::Plugin::Yancy).
The base Yancy class exists to provide a way to rapidly prototype a data-driven
web application. Apps that inherit from Yancy get these features out-of-the-box:
- The Yancy CMS ([Mojolicious::Plugin::Yancy](https://metacpan.org/pod/Mojolicious::Plugin::Yancy))
- Database editor ([Yancy::Plugin::Editor](https://metacpan.org/pod/Yancy::Plugin::Editor))
- User logins ([Yancy::Plugin::Auth](https://metacpan.org/pod/Yancy::Plugin::Auth))
- Role-based access controls ([Yancy::Plugin::Roles](https://metacpan.org/pod/Yancy::Plugin::Roles))
If you're familiar with developing Mojolicious applications, you can start
from the app skeleton at [https://github.com/preaction/Yancy/tree/master/eg/skeleton](https://github.com/preaction/Yancy/tree/master/eg/skeleton).
To begin writing a new application from scratch, create a `lib`
directory and add a `MyApp.pm` file that extends the `Yancy` class:
package MyApp;
use Mojo::Base 'Yancy', -signatures;
As in any other [Mojolicious](https://metacpan.org/pod/Mojolicious) app, add your routes, plugins, and other setup to
the `startup` method. Don't forget to call Yancy's ["startup"](#startup) method!
sub startup( $self ) {
$self->SUPER::startup;
# ... Add your routes and other setup here
}
Next, create a configuration file named `my_app.conf` to connect to your database:
{
backend => 'sqlite:my_app.db',
}
Last, create a [simple application script](https://docs.mojolicious.org/Mojolicious/Guides/Growing#Simplified-application-script)
named `script/my_app` to start your application:
#!/usr/bin/env perl
use Mojo::Base -strict;
use lib qw(lib);
use Mojolicious::Commands;
# Start command line interface for application
Mojolicious::Commands->start_app('MyApp');
Now you can run `./script/my_app daemon` to start your app!
To make developing your app easy and fun, make sure you're familiar with
these guides:
- [The Mojolicious tutorial and guides](https://docs.mojolicious.org)
- [The Yancy tutorial](https://metacpan.org/pod/Yancy::Guides::Tutorial)
- [The Yancy guides](https://metacpan.org/pod/Yancy::Guides)
# BUNDLED PROJECTS
This project bundles some other projects with the following licenses:
- [jQuery](http://jquery.com) (version 3.2.1) Copyright JS Foundation and other contributors (MIT License)
- [Bootstrap](http://getbootstrap.com) (version 4.3.1) Copyright 2011-2019 the Bootstrap Authors and Twitter, Inc. (MIT License)
- [Popper.js](https://popper.js.org) (version 1.13.0) Copyright 2017 Federico Zivolo (MIT License)
- [FontAwesome](http://fontawesome.io) (version 4.7.0) Copyright Dave Gandy (SIL OFL 1.1 and MIT License)
- [Vue.js](http://vuejs.org) (version 2.5.3) Copyright 2013-2018, Yuxi (Evan) You (MIT License)
- [marked](https://github.com/chjj/marked) (version 0.3.12) Copyright 2011-2018, Christopher Jeffrey (MIT License)
The bundled versions of these modules may change. If you rely on these in your own app,
be sure to watch the changelog for version updates.
# SEE ALSO
[Mojolicious](https://metacpan.org/pod/Mojolicious)
# AUTHOR
Doug Bell
# CONTRIBUTORS
- Boris Däppen
- Ed J
- Erik Johansen
- flash548 <59771551+flash548@users.noreply.github.com>
- Josh Rabinowitz
- Mohammad S Anwar
- Pavel Serikov
- Rajesh Mallah
- Roy Storey
- William Lindley
- Wojtek Bażant <wojciech.bazant+ebi@gmail.com>
# COPYRIGHT AND LICENSE
This software is copyright (c) 2021 by Doug Bell.
This is free software; you can redistribute it and/or modify it under
the same terms as the Perl 5 programming language system itself.