Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Y
yii2
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
PSDI Army
yii2
Commits
48e33b29
Commit
48e33b29
authored
Apr 25, 2014
by
Carsten Brandt
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update getting-started.md
Added alternative way of setting up dev environment.
parent
3838b501
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
38 additions
and
0 deletions
+38
-0
getting-started.md
docs/internals/getting-started.md
+38
-0
No files found.
docs/internals/getting-started.md
View file @
48e33b29
...
...
@@ -33,3 +33,41 @@ If you're not core developer or want to use your own fork for pull requests:
maintainer is the same for all extensions you require via composer.
Please refer to
[
Git workflow for Yii 2 contributors
](
git-workflow.md
)
for details about creating pull requests.
An Alternative way
------------------
1.
Clone your fork of yii2
`git clone git@github.com:<yourname>/yii2`
.
2.
Change into the repo folder
`cd yii2`
.
3.
run
`./build/build app/link basic`
to install composer dependecies for the basic app.
This command will install foreign composer packages as normal but will link the yii2 repo to
the currently checked out repo, so you have one instance of all the code installed.
4.
Do the same for the advanced app if needed:
`./build/build app/link advanced`
This command will also be used to update dependecies, it runs
`composer update`
internally.
5.
Now you have a working playground for hacking on Yii 2.
You may also add the yii2 upstream repo to pull the latest changes:
```
git remote add upstream https://github.com/yiisoft/yii2.git
```
### Unit tests
To run the unit tests you have to install composer packages for the dev-repo.
Run
`composer update`
in the repo root directory to get the latest packages.
You can now execute unit tests by running
`./vendor/bin/phpunit`
.
You may limit the tests to a group of tests you are working on e.g. to run only tests for the validators and redis
`./vendor/bin/phpunit --group=validators,redis`
.
### Extensions
To work on extensions you have to install them in the application you want to try them in.
Just add them to the
`composer.json`
as you would normally do e.g. add
`"yiisoft/yii2-redis": "*"`
to the
`require`
section of the basic app.
Running
`./build/build app/link basic`
will install the extension and its dependecies and create
a symlink to
`extensions/redis`
so you are not working the composer vendor dir but the yii2 repo directly.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment