Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 54fb6c1

Browse files
committedJun 29, 2014
Merge pull request coderwall#25 from sachinm/master
DOC updates [skip ci]
2 parents 702497e + 8ae9177 commit 54fb6c1

File tree

3 files changed

+111
-70
lines changed

3 files changed

+111
-70
lines changed
 

‎CONTRIBUTING.md

+57-60
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,24 @@
1-
# Contributing
2-
31
## **Protip for Contributors**
42

53
When committing a Pull Request for non-application/test code please add [`[skip ci]`](http://docs.travis-ci.com/user/how-to-skip-a-build/) to your commit message.
64

7-
## External Dependencies
5+
# Contributing
86

9-
There are a couple of steps you need to take before contributing:
7+
Here are the steps for getting setup & started with contributing to CoderWall :
108

119
1. Go to [https://assemblymade.com/coderwall](https://assemblymade.com/coderwall) and sign up.
1210
2. Link your GitHub account to your Assembly account in your profile settings.
13-
3. Create a new WIP at [https://assemblymade.com/coderwall/wips](https://assemblymade.com/coderwall/wips).
11+
3. [Fork the code](https://github.com/assemblymade/coderwall).
12+
4. Create a new WIP at [https://assemblymade.com/coderwall/wips](https://assemblymade.com/coderwall/wips).
13+
5. Get vagrant running
14+
6. Run the test suite
15+
7. If you have any issues, jump into chat, introduce yourself and ask or leave a message if no one is around.
16+
8. Find an [interesting bounty](https://assemblymade.com/coderwall/wips) on Assembly or suggest a new one.
17+
9. Fork and then issue a PR when you are done referencing the Bounty. (Note: Only PRs from those with valid Assembly account will be merged).
18+
19+
You're on your way to having a stake in CoderWall.
1420

15-
Then just go ahead, fork the repo & issue a pull request. You're on your way to having a stake in Coderwall.
21+
## External Dependencies
1622

1723
### Stripe configuration
1824

@@ -32,12 +38,9 @@ You're free to not use Vagrant but by the time you're done setting up you'll pro
3238

3339
### How to work on Coderwall using Vagrant on VirtualBox
3440

35-
Sure you could download and install all the dependencies, services, and whatnot
36-
on to your local workstation but ain't nobody got time for that mess.
41+
Sure you could download and install all the dependencies, services, and what not on to your local workstation but ain't nobody got time for that mess.
3742

38-
To save time and headaches we use Vagrant. Vagrant is a automation tool for
39-
VirtualBox that will help you spin up a virtual environment with pretty much
40-
everything in place and ready for you to start hacking (even on Windows!)
43+
To save time and headaches we use Vagrant. Vagrant is a automation tool for VirtualBox that will help you spin up a virtual environment with pretty much everything in place and ready for you to start hacking (even on Windows!)
4144

4245
Here's everything you need to get started working on Coderwall with Vagrant TODAY!
4346

@@ -53,22 +56,23 @@ There's only a VirtualBox basebox right now.
5356

5457
#### Vagrant? VirtualBox? Let's take this one step at a time.
5558

59+
If you're running Windows, [here's a guide written by one of our members on how to get set up.](https://github.com/assemblymade/coderwall/docs/getting_started_on_windows.md)
60+
5661
1. **Install VirtualBox**
5762

5863
Grab the VirtualBox installer from **[here](https://www.virtualbox.org/wiki/Downloads)**.
5964

6065
_At the time of writing this documentation the current version is VirtualBox 4.3.10._
6166

62-
You don't have to install the VirtualBox 4.3.10 Oracle VM VirtualBox Extension Pack
63-
but I recommend installing it for the extra drivers.
67+
You don't have to install the VirtualBox 4.3.10 Oracle VM VirtualBox Extension Pack but I recommend installing it for the extra drivers.
6468

6569
2. **Install Vagrant**
6670

67-
Grab the Vagrant installer from **[here](http://www.vagrantup.com/downloads.html)**.
68-
71+
[Vagrant](http://vagrantup.com) is the recommended way to run CoderWall on your own machine. You need to download and install.
72+
Grab the Vagrant installer from **[here](http://www.vagrantup.com/downloads.html)**.
6973
_At the time of writing this documentation the current version is Vagrant 1.6.2._
70-
71-
Follow the installation instructions for your platform on the Vagrant download page.
74+
75+
Follow the installation instructions for your platform on the Vagrant download page.
7276

7377
After installing Vagrant we need to add a couple plugins.
7478

@@ -80,32 +84,27 @@ There's only a VirtualBox basebox right now.
8084

8185
3. **Git assemblymade/coderwall**
8286

83-
mkdir -p ~/assemblymade
84-
cd ~/assemblymade
85-
git clone git@github.com:assemblymade/coderwall.git
86-
87-
I am going to assume that the project is cloned into your home directory in
88-
and into a directory structure like `~/assemblymade/coderwall`.
87+
mkdir -p ~/assemblymade
88+
cd ~/assemblymade
89+
90+
depending on your choice of protocols : _(this will take a while to run so you may want to grab some coffee)_
91+
* git clone https://github.com/assemblymade/coderwall.git coderwall
92+
* git clone git@github.com:assemblymade/coderwall.git coderwall
93+
94+
I am going to assume that the project is cloned into your home directory in and into a directory structure like `~/assemblymade/coderwall`.
8995

9096
4. **Fire it up! Fire it up! Fire it up!**
9197

92-
Now that you've got VirtualBox and Vagrant installed with the source code
93-
cloned in `~/assemblymade/coderwall` we can start up the Vagrant instance.
98+
Now that you've got VirtualBox and Vagrant installed with the source code cloned in `~/assemblymade/coderwall` we can start up the Vagrant instance.
9499

95100
cd ~/assemblymade/coderwall
96101
vagrant up
97102

98-
You will likely be prompted for your `sudo` password to allow VirtualBox
99-
to mount the shared folder using NFS.
103+
You will likely be prompted for your `sudo` password to allow VirtualBox to mount the shared folder using NFS.
100104

101-
Since this is probably the first time you're running this command it's going
102-
to take a VERY long time (bandwidth willing) to run. This is because Vagrant
103-
needs to fetch the Coderwall base box from the Internet and it's about 1GB.
104-
Fortunately that really only has to be done once (unless the base box get's
105-
updated but that's another story).
105+
Since this is probably the first time you're running this command it's going to take a VERY long time (bandwidth willing) to run. This is because Vagrant needs to fetch the Coderwall base box from the Internet and it's about 1GB. Fortunately that really only has to be done once (unless the base box get's updated but that's another story).
106106

107-
Once Vagrant reports that you're booted up and ready to go then you'll be
108-
able to SSH into the local vm similiar to any other remote box.
107+
Once Vagrant reports that you're booted up and ready to go then you'll be able to SSH into the local vm similiar to any other remote box.
109108

110109
# still in ~/assemblymade/coderwall
111110
vagrant ssh
@@ -118,60 +117,58 @@ There's only a VirtualBox basebox right now.
118117
Now that you're SSH'ed into the Vagrant VM it's time to run the app.
119118

120119
# we're still SSH'ed into Vbox
121-
cd ~/web
120+
cd ~/assemblymade
122121
rvm current # should be ruby-2.1.0@coderwall
123122
bundle check # should be a response that everything's good
124123
bundle exec rails server
125124

126125
If all went well the Rails server should start up on PORT 3000.
127126

128-
Now go open your favorite web browser on you host machine and
129-
navigate to `http://localhost:3000`.
127+
Now go open your favorite web browser on you host machine and navigate to [http://localhost:3000](http://localhost:3000).
130128

131-
If all goes well (and if it doesn't then check if another app is
132-
running on port 3000 and if there's any logging output being displayed
133-
in the window you were running Vagrant in) then you're going to be
134-
looking at the Coderwall homepage.
129+
If all goes well (and if it doesn't then check if another app is running on port 3000 and if there's any logging output being displayed in the window you were running Vagrant in) then you're going to be looking at the CoderWall homepage.
135130

136-
Congratulations! NOW GET TO WORK! Enough dilly-dallying with your devenv.
131+
Congratulations! NOW GET TO WORK! Enough dilly-dallying with your DEV env.
137132

138133
5. **Hackety Hack!**
139134

140-
Vagrant is powerful not just because it can abstract away the mess of
141-
managing a crazy, complicated development environment while ensuring everyone
142-
has a common platform to work on. It's also powerful because it will still
143-
let you have whatever crazy, complicated editors and tools to work on your
144-
code while abstracting away the nasty details of installing and configuring Postgres.
135+
Vagrant is powerful not just because it can abstract away the mess of managing a crazy, complicated development environment while ensuring everyone has a common platform to work on. It's also powerful because it will still let you have whatever crazy, complicated editors and tools to work on your code while abstracting away the nasty details of installing and configuring Postgres.
145136

146-
If you're on your host computer and navigate to `~/assemblymade/coderwall` (we're all there, right?)
147-
and make changes to your code while Vagrant is running you'll be able to see the changes
148-
reflected in Vagrant immediately. Try this.
137+
If you're on your host computer and navigate to `~/assemblymade/coderwall` (we're all there, right?) and make changes to your code while Vagrant is running you'll be able to see the changes reflected in Vagrant immediately. Try this.
149138

150139
cd ~/assemblymade/coderwall
151140
echo Hello, `whoami` from `hostname` >> HELLO.txt
152141
vagrant ssh
153-
cd ~/web
142+
cd ~/assemblymade
154143
cat HELLO.txt #whoa.
155144
echo Hello, `whoami` from `hostname` >> HELLO.txt
156145
exit
157146
cat HELLO.txt # wah-wah-wee-wa!
158147
rm -f HELLO.txt # yeah, it's deleted in the other spot too.
159148

160-
Yeah, that's pretty awesome. Remember that NFS thing we glossed over earlier? That's
161-
the mechanism that Vagrant set up with VirtualBox to transparently synchronize your
162-
local folder with the folder on the VM. Now you can edit and manage your files from
163-
the comfort of your favorite OS without having to worry about copying them to the VM.
149+
Yeah, that's pretty awesome. Remember that NFS thing we glossed over earlier? That's the mechanism that Vagrant set up with VirtualBox to transparently synchronize your local folder with the folder on the VM. Now you can edit and manage your files from the comfort of your favorite OS without having to worry about copying them to the VM.
164150

165-
6. **All done.**
151+
6. **All done for the day - Turning your Vagrant VM off**
166152

167153
When you're ready to call it a day and want to turn the VM off you have two options.
168154

169155
You can either "turn the VM off" using `vagrant halt` or you can suspend the VM using `vagrant suspend`.
170156

171157
Either way when you're ready to resume working just `vagrant up` and you're good to go.
172158

173-
7. **Thanks**
159+
7. Gems Installation and Database Migration
160+
161+
Remember that you are using Vagrant, so if you run ```bundle install``` or ```rake db:migrate``` directly in your terminal it will not affect the virtual machine where CoderWall is running.
162+
163+
In order to run these commands, in the virtual machine, all you have to do is to run ```vagrant provision```.
164+
165+
8. Environment Variables
166+
167+
If you need to change any environment variable you have to edit ```.env``` file properly and restart Rails server running:
168+
169+
vagrant ssh -c "sudo restart coderwall"
170+
171+
172+
9. **Thanks**
174173

175-
I hope you enjoy working with Vagrant as much as we do and feel free to ask questions
176-
if you get stuck or have a problem. You're probably not alone and even if you're the
177-
first to encounter a rough patch you won't be the last.
174+
I hope you enjoy working with Vagrant as much as we do and feel free to ask questions if you get stuck or have a problem. You're probably not alone and even if you're the first to encounter a rough patch you won't be the last.

‎README.md

-10
Original file line numberDiff line numberDiff line change
@@ -15,16 +15,6 @@ When committing a Pull Request for non-application/test code please add [`[skip
1515

1616
Please see our [/master/CONTRIBUTING.md](https://github.com/assemblymade/coderwall/blob/master/CONTRIBUTING.md) for instructions on how to set up your development environment for Coderwall.
1717

18-
**TL;DR**
19-
20-
1. Create an [Assembly account](https://assemblymade.com).
21-
2. [Fork the code](https://github.com/assemblymade/coderwall)
22-
3. Get vagrant running
23-
4. Run the test suite
24-
5. If you have any issues, jump into chat, introduce yourself and ask or leave a message if no one is around.
25-
6. Find an [interesting bounty](https://assemblymade.com/coderwall/wips) on Assembly or suggest a new one.
26-
7. Fork and then issue a PR when you are done referencing the Bounty. (Note: Only PRs from those with valid Assembly account will be merged).
27-
2818
## Built With
2919

3020
Coderwall is built from the following open source components:

‎docs/getting_started_on_windows.md

+54
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
# Getting Started on Windows
2+
3+
I wrote this guide after having trouble getting CoderWall to work on my computer. If you're a beginner to this and want to help build, this guide is for you!
4+
5+
## First Steps
6+
7+
To run CoderWall on Windows you'll need to download and install three programs on your computer. Make sure to have administrator privileges. I believe that your computer should also be 64-bit, not 32-bit. [Here's a guide on how to find out.](http://windows.microsoft.com/en-ca/windows/32-bit-and-64-bit-windows)
8+
9+
###[Git](http://git-scm.com/downloads)
10+
You need Git to be able to clone the CoderWall repository on GitHub. On the installer, make sure to select the option that allows you to use Git in the Windows Command Prompt.
11+
12+
###[VirtualBox](https://www.virtualbox.org/wiki/Downloads)
13+
Vagrant needs VirtualBox to create its virtual environment. You might not be able to run VirtualBox if your processor doesn't support virtualization. If you think it does, and later on it doesn't work, your computer BIOS might have disabled the feature. Check out the [Troubleshooting section below.](https://github.com/assemblymade/coderwall/docs/getting_started_on_windows.md#troubleshooting)
14+
15+
###[Vagrant](http://vagrantup.com)
16+
You need Vagrant to be able to create the development environment.
17+
18+
Once you've got all that done, restart your computer!
19+
20+
## Part Two
21+
22+
###Clone the CoderWall repo
23+
Start the Command Prompt. Type the following in and press enter
24+
25+
depending on your choice of protocols : _(this will take a while to run so you may want to grab some coffee)_
26+
git clone https://github.com/assemblymade/coderwall.git coderwall
27+
git clone git@github.com:assemblymade/coderwall.git coderwall
28+
29+
Next type in
30+
31+
cd CoderWall
32+
33+
### Start Vagrant
34+
35+
This is a simple command. Ready? Enter in
36+
37+
vagrant up
38+
39+
Vagrant should now connect and begin to download the box needed to set things up. This will take a bit of time, but only needs to be downloaded once. If you're getting an error message, I've put some troubleshooting stuff below.
40+
41+
When you're done, you have a virtual machine box open, and you should be able to access [http://localhost:3000](http://localhost:3000)
42+
43+
44+
## Troubleshooting
45+
46+
If Vagrant says that it can't find the `VBoxManage` binary, you will need to set up the path for VirtualBox. Go to Control Panel and find the "System Environment Variables" setting. Then add
47+
48+
c:\Program Files\Oracle\VirtualBox
49+
50+
to your PATH variable. Make sure to add a semicolon if there are other files listed there already. [There's a good guide on how to set it here.](http://www.computerhope.com/issues/ch000549.htm)
51+
52+
If VirtualBox isn't starting up the virtual machine, you might need to edit the BIOS. Entering BIOS is different for each computer manufacturer, so you will need to search that up. After you're able to get into BIOS, the setting to enable 'Virtualization Technology' should be under the 'Security' tab.
53+
54+
If you're getting a timeout error, where your computer is unable to connect to the virtual machine, I haven't been able to find a solution to that yet :(

0 commit comments

Comments
 (0)
Please sign in to comment.