fredit 0.1.7 → 0.1.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/Gemfile +1 -0
- data/README.md +33 -23
- metadata +13 -13
data/Gemfile
CHANGED
data/README.md
CHANGED
@@ -1,10 +1,10 @@
|
|
1
1
|
# fredit: front-end edit
|
2
2
|
|
3
|
-
|
3
|
+
fredit is a very simple, no-frills Rails 3 Engine that lets you edit your
|
4
4
|
Rails application's view templates, css stylesheets, and javascript
|
5
5
|
files (a.k.a front-end files) through the browser.
|
6
6
|
|
7
|
-
|
7
|
+
fredit injects an edit link into every view template. These edit links
|
8
8
|
are visible wherever the template is rendered, whether it is a layout,
|
9
9
|
a page, or a partial.
|
10
10
|
|
@@ -17,10 +17,10 @@ and alter the underlying source files.
|
|
17
17
|
<img style="width:300px" src="https://github.com/danchoi/fredit/raw/master/screens/fredit.png"/>
|
18
18
|
|
19
19
|
In addition to view templates, stylesheets and javascript files are
|
20
|
-
accessible through a file selection drop down at the top of the
|
20
|
+
accessible through a file selection drop down at the top of the fredit
|
21
21
|
edit page.
|
22
22
|
|
23
|
-
You can also create and delete front-end files on the
|
23
|
+
You can also create and delete front-end files on the fredit edit page.
|
24
24
|
|
25
25
|
**NOTE: Currently only the ERB Rails template handler is supported.**
|
26
26
|
You are welcome to fork and add support for Haml and other template
|
@@ -54,19 +54,19 @@ addition to being quite heavyweight, this approach is too restrictive when
|
|
54
54
|
you want to give your collaborator as much control over the front-end as
|
55
55
|
he or she can handle.
|
56
56
|
|
57
|
-
|
58
|
-
application without the hassles of having to set up and run a
|
59
|
-
instance of it
|
60
|
-
|
61
|
-
|
57
|
+
fredit lets a collaborator make significant front-end contributions to a
|
58
|
+
Rails application without the hassles of having to set up and run a
|
59
|
+
local instance of it. Just run a fredit-enabled instance of your Rails
|
60
|
+
app on a server that your collaborator can access through his or her
|
61
|
+
browser. This fredit-enabled instance can have its own Rails
|
62
62
|
environment, database, and git branch.
|
63
63
|
|
64
64
|
|
65
65
|
## Install and setup
|
66
66
|
|
67
|
-
|
67
|
+
fredit requires Rails 3.
|
68
68
|
|
69
|
-
|
69
|
+
fredit works best as a gem you include in a specific Rails
|
70
70
|
environment. Put something like this in the `Gemfile` of your Rails app:
|
71
71
|
|
72
72
|
source 'http://rubygems.org'
|
@@ -80,28 +80,28 @@ environment. Put something like this in the `Gemfile` of your Rails app:
|
|
80
80
|
and then run `RAILS_ENV=staging bundle install`, adjusting the
|
81
81
|
`RAILS_ENV` to your target environment.
|
82
82
|
|
83
|
-
To run your Rails app with
|
84
|
-
environment Gemfile group you put the
|
83
|
+
To run your Rails app with fredit, just start it in the Rails
|
84
|
+
environment Gemfile group you put the fredit gem in. When you hit the
|
85
85
|
app in the browser, you should see the injected view template links and
|
86
|
-
be able to click through them to
|
86
|
+
be able to click through them to fredit's source code editor.
|
87
87
|
|
88
88
|
|
89
89
|
## fredit with git
|
90
90
|
|
91
|
-
|
91
|
+
fredit assumes that the Rails instance it is running on is a cloned git
|
92
92
|
repository. **It also assumes that you have set the current branch of
|
93
93
|
this git repository to the one you want your collaborator's changes
|
94
94
|
committed to.**
|
95
95
|
|
96
|
-
When your collaborator makes changes,
|
96
|
+
When your collaborator makes changes, fredit will commit those changes
|
97
97
|
on the current git branch of this clone of the git repository. There is
|
98
|
-
a form field in the
|
98
|
+
a form field in the fredit editor for the collaborator to enter git
|
99
99
|
author information and a git log message. These bits of information
|
100
100
|
will be added as metadata to the git commit.
|
101
101
|
|
102
102
|
When you're ready to review and merge the changes your collaborator made
|
103
|
-
via
|
104
|
-
branches. You can set up client-side git hooks on the
|
103
|
+
via fredit, it's all just a matter of working with git commits and
|
104
|
+
branches. You can set up client-side git hooks on the fredit-enabled
|
105
105
|
clone to notify you when your collaborator has made changes, to
|
106
106
|
automatically push those changes to the appropriate branch in the
|
107
107
|
upstream repository, run a CI build server, etc.
|
@@ -109,10 +109,20 @@ upstream repository, run a CI build server, etc.
|
|
109
109
|
|
110
110
|
## Security
|
111
111
|
|
112
|
-
|
113
|
-
|
114
|
-
|
115
|
-
|
112
|
+
fredit has rudimentary security features. fredit will not allow any user
|
113
|
+
to use the fredit web interface to edit a file above or outside the
|
114
|
+
Rails application root directory of that Rails instance. But this still
|
115
|
+
leaves things like database.yml configurations accessible to the fredit
|
116
|
+
editor. Anyone with access to the fredit editing interface will have the
|
117
|
+
power to run arbitrary SQL on your environment's database.
|
118
|
+
|
119
|
+
So please take additional precautions to make sure that your
|
120
|
+
fredit-enabled Rails instance is not accessible by hostile strangers.
|
121
|
+
At a minimum, use Apache Basic Authentication or the like to restrict
|
122
|
+
access to this entire Rails instance.
|
123
|
+
|
124
|
+
It's probably not a good idea to run a fredit-enabled Rails app on a
|
125
|
+
server with important stuff on it. Use a scratch staging server.
|
116
126
|
|
117
127
|
|
118
128
|
## Contribute
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: fredit
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.8
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -13,7 +13,7 @@ date: 2011-10-25 00:00:00.000000000Z
|
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: git
|
16
|
-
requirement: &
|
16
|
+
requirement: &70153551354840 !ruby/object:Gem::Requirement
|
17
17
|
none: false
|
18
18
|
requirements:
|
19
19
|
- - ! '>='
|
@@ -21,7 +21,7 @@ dependencies:
|
|
21
21
|
version: '0'
|
22
22
|
type: :runtime
|
23
23
|
prerelease: false
|
24
|
-
version_requirements: *
|
24
|
+
version_requirements: *70153551354840
|
25
25
|
description: Edit the front end of Rails apps through the browser.
|
26
26
|
email:
|
27
27
|
- dhchoi@gmail.com
|
@@ -29,20 +29,20 @@ executables: []
|
|
29
29
|
extensions: []
|
30
30
|
extra_rdoc_files: []
|
31
31
|
files:
|
32
|
-
- app/views/layouts/fredit.html.erb
|
33
|
-
- app/views/fredit/show.html.erb
|
34
|
-
- app/views/fredit/revision.html.erb
|
35
32
|
- app/controllers/fredit_controller.rb
|
36
|
-
-
|
37
|
-
-
|
38
|
-
-
|
33
|
+
- app/views/fredit/revision.html.erb
|
34
|
+
- app/views/fredit/show.html.erb
|
35
|
+
- app/views/layouts/fredit.html.erb
|
39
36
|
- lib/fredit/engine.rb
|
37
|
+
- lib/fredit/erb.rb
|
38
|
+
- lib/fredit/erb31.rb
|
39
|
+
- lib/fredit.rb
|
40
40
|
- config/routes.rb
|
41
41
|
- MIT-LICENSE
|
42
42
|
- Rakefile
|
43
43
|
- Gemfile
|
44
44
|
- README.md
|
45
|
-
homepage:
|
45
|
+
homepage: https://github.com/danchoi/fredit
|
46
46
|
licenses: []
|
47
47
|
post_install_message:
|
48
48
|
rdoc_options: []
|
@@ -56,7 +56,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
56
56
|
version: '0'
|
57
57
|
segments:
|
58
58
|
- 0
|
59
|
-
hash: -
|
59
|
+
hash: -4259262550981050776
|
60
60
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
61
61
|
none: false
|
62
62
|
requirements:
|
@@ -65,10 +65,10 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
65
65
|
version: '0'
|
66
66
|
segments:
|
67
67
|
- 0
|
68
|
-
hash: -
|
68
|
+
hash: -4259262550981050776
|
69
69
|
requirements: []
|
70
70
|
rubyforge_project:
|
71
|
-
rubygems_version: 1.8.
|
71
|
+
rubygems_version: 1.8.6
|
72
72
|
signing_key:
|
73
73
|
specification_version: 3
|
74
74
|
summary: Edit the front end of Rails apps through the browser.
|