Skip to content
A CLI to bootstrap a "zero-configuration" application for the Cozy V3 platform
JavaScript Shell HTML Vue CSS Smarty
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
docs
packages
.eslintrc.json
.gitignore
.travis.yml fix: 🔧 Force node v10 usage Jul 1, 2019
CHANGELOG.md release: 💎 Update changelog for next release + reset lockfiles (globa… Jul 11, 2019
CHANGELOG_v0.md
CHANGELOG_v1.md
CreateCozyApp.png
LICENSE
README.md
jest.config.js fix: add babel transform config into global jest.config Jun 26, 2019
lerna.json
package.json
renovate.json chore: move babel and eslint cozy-app packages to cozy-libs Aug 9, 2018
reset_yarn.sh
yarn.lock

README.md

CCA illustration

Create Cozy App

Start quickly your Cozy application

What's create-cozy-app?

create-cozy-app is a command line tool that creates a skeleton of an application for Cozy, using Cozy libraries.

This tool can be run as an installed CLI or by using yarn create, see below for more information.

By default, create-cozy-app will use the cozy-scripts scripts bundle to build your app based on React. But option for VueJS or Vanilla are also available, see below for more information.

You can find a complete tutorial about creating a Cozy application using create-cozy-app in the official documentation (docs.cozy.io).

ℹ️ The packages babel-preset-cozy-app and eslint-config-cozy-app have been moved to the cozy-libs repository since their version 1.0.0.

Requirements

Running it via Yarn directly (highly recommended)

You can use create-cozy-app without installing it globally by using the yarn create cozy-app command to bootstrap your application:

yarn create cozy-app mycozyapp

You can find more information about yarn create in the yarnpkg documentation.

Running it using the installed CLI

By installed the CLI, you will have to update it regularly to keep the app template up to date. It is why we recommend to use directly yarn like above which will always uses the last version of the CLI.

Install

Just use yarn to download and globally install the create-cozy-app CLI;

yarn global add create-cozy-app

CLI usage

Then, use the create-cozy-app command to bootstrap your application:

create-cozy-app mycozyapp

Ready to go

The script will download some dependencies (may take a while) and ask you a few questions, then creates an application skeleton inside mycozyapp.

That's it! You can already tart hacking:

cd mycozyapp
yarn start

After the webpack build and the docker environment ready, the mycozyapp app here will be available at http://mycozyapp.cozy.tools:8080

Options

--scripts-source (useful for hacking)

You can pass a custom scripts package using the optional --scripts-source option, it can be one of:

  • a relative local path to a tarball (fileRel: prefix): fileRel:./a-folder/my-cozy-scripts.tar.gz
  • an absolute local path to a tarball (fileAbs: prefix): fileAbs:/root/my-cozy-scripts.tar.gz
  • an URL to a tarball (url: prefix): url:https://myurl.com/my-cozy-scripts.tar.gz
  • a specific npm version (version: prefix): version:0.1.5
  • a specific git commit/branch with name provided after the '#' (git: prefix): git://github.com/CPatchane/cozy-scripts.git#master
--vue

Using this options, create-cozy-app will use the cozy-scripts package but with the template-vue template folder in order to build a Cozy application using the VueJS 2+ framework.

--vanilla

Using this options, create-cozy-app will use the cozy-scripts-vanilla package (instead of the default one: cozy-scripts) and build a Cozy application in VanillaJS without any npm dependencies.

--verbose

Using this options, create-cozy-app will be run in a more verbose way, useful for debugging or understanding what the script does.

Community

What's Cozy?


Cozy is a platform that brings all your web services in the same private space. With it, your webapps and your devices can share data easily, providing you with a new experience. You can install Cozy on your own hardware where no one's tracking you.

Get in touch

You can reach the Cozy Community by:

License

create-cozy-app is distributed under the MIT license.

CCA logo by @CPatchane.

Credits

A big thanks to @CPatchane, the original author of Create-Cozy-App (CCA) tools.

You can’t perform that action at this time.