forked from ChicagoBoss/ChicagoBoss
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathREADME_UPGRADE
85 lines (59 loc) · 2.71 KB
/
README_UPGRADE
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
Upgrade: From 0.5 to 0.6
------------------------
Starting with Chicago Boss 0.6, projects follow an OTP layout, and the admin
interface is a standalone OTP application.
To upgrade, you will need to do the following in your project:
mkdir src
mkdir priv
mv controller/ init/ lib/ mail/ model/ test/ view/ src/
mv lang/ static/ priv/
PROJECT=my_application mv boss.routes priv/$PROJECT.routes
In addition, you will need to prefix your controller modules with the application
name. E.g.
mv blog_controller.erl my_application_blog_controller.erl
This avoids module naming conflicts when multiple applications are installed on
the same server (which was not possible prior to 0.6).
Upgrade: From 0.5.x to 0.5.y
----------------------------
Starting with Chicago Boss 0.5, the framework source is kept separate from your
project source. After downloading and building a new copy of CB, you need to update
your server scripts to point to the new source. Open "start-dev.sh" and "start.sh"
and make sure there is an argument like this:
-pa /path/to/new/ChicagoBoss/ebin
You might also want to update your /admin interface by copying the "skel/admin"
directory from the new CB over to your project directory.
Upgrade: From 0.4 to 0.5
------------------------
The easiest way to upgrade from 0.4 is to create a new CB app and copy your source
into it. In the CB source directory, type:
make
make app PROJECT=mynewproject
cd ../mynewproject
cp -a /path/to/existing/project/view \
/path/to/existing/project/model \
/path/to/existing/project/controller \
/path/to/existing/project/static \
/path/to/existing/project/boss.config \
.
Then start the server with ./start-dev.sh
Upgrade: From 0.4.x to 0.4.y
----------------------------
Starting with Chicago Boss 0.4, application upgrades are as simple as:
cp -a /path/to/old/ChicagoBoss/[a-z]* .
In general, files in the project directory that start with an upper-case letter
belong to Boss. Files which start with a lower-case letter belong to you.
Upgrade: From 0.3 to 0.4
------------------------
The directory structure has changed somewhat. The MVC files have moved around, and
files for the /admin interface are in a separate directory (ADMIN).
The following steps should get you most of the way to an upgrade:
cp -a /path/to/old/ChicagoBoss/boss.config .
cp -a /path/to/old/ChicagoBoss/Web/*_controller.erl controller/
rm controller/admin_controller.erl
cp -a /path/to/old/ChicagoBoss/Web/*.erl lib/
cp -a /path/to/old/ChicagoBoss/Model/* model/
cp -a /path/to/old/ChicagoBoss/Web/*_views view/
rm -r view/admin_views
cp -a /path/to/old/ChicagoBoss/static/* static/
make clean
make