Skip to content

Commit c814826

Browse files
jareddonovancatarak
authored andcommitted
Remove EXAMPLE_USERNAME as a settable option as per discussion on Issue #646 (#651)
1 parent 9958619 commit c814826

File tree

3 files changed

+8
-11
lines changed

3 files changed

+8
-11
lines changed

.env.example

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,5 @@ GITHUB_SECRET=<your-github-client-secret>
1111
GOOGLE_ID=<your-google-client-id> (use google+ api)
1212
GOOGLE_SECRET=<your-google-client-secret> (use google+ api)
1313
MAILGUN_KEY=<your-mailgun-api-key>
14-
EXAMPLE_USERNAME=<your-name>
1514
EXAMPLE_USER_EMAIL=<your-email-id>
1615
EXAMPLE_USER_PASSWORD=<your-password>

README.md

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -26,9 +26,8 @@ This project is currently in development! It will be announced when there is a (
2626
GOOGLE_ID=<your-google-client-id> (use google+ api)
2727
GOOGLE_SECRET=<your-google-client-secret> (use google+ api)
2828
MAILGUN_KEY=<your-mailgun-api-key>
29-
EXAMPLE_USERNAME=<your-name>
30-
EXAMPLE_USER_EMAIL=<your-email-id>
31-
EXAMPLE_USER_PASSWORD=<your-password>
29+
EXAMPLE_USER_EMAIL=<email-id-for-p5-example-user>
30+
EXAMPLE_USER_PASSWORD=<password-for-p5-example-user>
3231
```
3332

3433
If you don't care about being able to upload media files to S3 or Login with Github or Google, you can drop in the file exactly how it is. Or, if you don't want to do that, just ask me to send you mine. Refer to [this gist](https://gist.github.com/catarak/70c9301f0fd1ac2d6b58de03f61997e3) for creating an S3 bucket for testing, or if you don't want to do that, I can add you to one of my S3 buckets.
@@ -93,9 +92,8 @@ If you don't have the full server environment running, you can launch a one-off
9392
MAILGUN_KEY=<mailgun-api-key>
9493
MAILGUN_DOMAIN=<mailgun-domain>
9594
EMAIL_VERIFY_SECRET_TOKEN=whatever_you_want_this_to_be_it_only_matters_for_production
96-
EXAMPLE_USERNAME=<your-name>
97-
EXAMPLE_USER_EMAIL=<your-email-id>
98-
EXAMPLE_USER_PASSWORD=<your-password>
95+
EXAMPLE_USER_EMAIL=<email-id-for-p5-example-user>
96+
EXAMPLE_USER_PASSWORD=<password-for-p5-example-user>
9997
```
10098
For production, you will need to have real Github and Amazon credentials. Refer to [this gist](https://gist.github.com/catarak/70c9301f0fd1ac2d6b58de03f61997e3) for creating an S3 bucket for testing.
10199

server/examples.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,7 @@ function createProjectsInP5user(projectsInAllCategories) {
137137
};
138138

139139
rp(options).then((res) => {
140-
User.findOne({ username: process.env.EXAMPLE_USERNAME }, (err, user) => {
140+
User.findOne({ username: 'p5' }, (err, user) => {
141141
if (err) throw err;
142142

143143
eachSeries(projectsInAllCategories, (projectsInOneCategory, categoryCallback) => {
@@ -289,19 +289,19 @@ function createProjectsInP5user(projectsInAllCategories) {
289289
}
290290

291291
function getp5User() {
292-
User.findOne({ username: process.env.EXAMPLE_USERNAME }, (err, user) => {
292+
User.findOne({ username: 'p5' }, (err, user) => {
293293
if (err) throw err;
294294

295295
let p5User = user;
296296
if (!p5User) {
297297
p5User = new User({
298-
username: process.env.EXAMPLE_USERNAME,
298+
username: 'p5',
299299
email: process.env.EXAMPLE_USER_EMAIL,
300300
password: process.env.EXAMPLE_USER_PASSWORD
301301
});
302302
p5User.save((saveErr) => {
303303
if (saveErr) throw saveErr;
304-
console.log(`Created a user p5${p5User}`);
304+
console.log(`Created a user p5 ${p5User}`);
305305
});
306306
}
307307

0 commit comments

Comments
 (0)