Skip to content
This repository was archived by the owner on Mar 6, 2024. It is now read-only.

Commit 0fd347f

Browse files
author
Miyako Jones
committed
Added Code of Conduct, contribution guidelines, issue templates. Updated readme.
1 parent ba68031 commit 0fd347f

File tree

7 files changed

+182
-29
lines changed

7 files changed

+182
-29
lines changed

CODE_OF_CONDUCT.md

Lines changed: 77 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,77 @@
1+
# Contributor Covenant Code of Conduct
2+
3+
## Our Pledge
4+
5+
In the interest of fostering an open and welcoming environment, we as
6+
contributors and maintainers pledge to making participation in our project and
7+
our community a harassment-free experience for everyone, regardless of age, body
8+
size, disability, ethnicity, sex characteristics, gender identity and expression,
9+
level of experience, education, socio-economic status, nationality, personal
10+
appearance, race, religion, or sexual identity and orientation.
11+
12+
## Our Standards
13+
14+
Examples of behavior that contributes to creating a positive environment
15+
include:
16+
17+
* Using welcoming and inclusive language
18+
* Being respectful of differing viewpoints and experiences
19+
* Gracefully accepting constructive criticism
20+
* Focusing on what is best for the community
21+
* Showing empathy towards other community members
22+
23+
Examples of unacceptable behavior by participants include:
24+
25+
* The use of sexualized language or imagery and unwelcome sexual attention or
26+
advances
27+
* Trolling, insulting/derogatory comments, and personal or political attacks
28+
* Public or private harassment
29+
* Publishing others' private information, such as a physical or electronic
30+
address, without explicit permission
31+
* Other conduct which could reasonably be considered inappropriate in a
32+
professional setting
33+
34+
## Our Responsibilities
35+
36+
Project maintainers are responsible for clarifying the standards of acceptable
37+
behavior and are expected to take appropriate and fair corrective action in
38+
response to any instances of unacceptable behavior.
39+
40+
Project maintainers have the right and responsibility to remove, edit, or
41+
reject comments, commits, code, wiki edits, issues, and other contributions
42+
that are not aligned to this Code of Conduct, or to ban temporarily or
43+
permanently any contributor for other behaviors that they deem inappropriate,
44+
threatening, offensive, or harmful.
45+
46+
## Scope
47+
48+
This Code of Conduct applies both within project spaces and in public spaces
49+
when an individual is representing the project or its community. Examples of
50+
representing a project or community include using an official project e-mail
51+
address, posting via an official social media account, or acting as an appointed
52+
representative at an online or offline event. Representation of a project may be
53+
further defined and clarified by project maintainers.
54+
55+
## Enforcement
56+
57+
Instances of abusive, harassing, or otherwise unacceptable behavior may be
58+
reported by contacting the project team at smartsweeper@swiftlet.technology. All
59+
complaints will be reviewed and investigated and will result in a response that
60+
is deemed necessary and appropriate to the circumstances. The project team is
61+
obligated to maintain confidentiality with regard to the reporter of an incident.
62+
Further details of specific enforcement policies may be posted separately.
63+
64+
Project maintainers who do not follow or enforce the Code of Conduct in good
65+
faith may face temporary or permanent repercussions as determined by other
66+
members of the project's leadership.
67+
68+
## Attribution
69+
70+
This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4,
71+
available at https://www.contributor-covenant.org/version/1/4/code-of-conduct.html
72+
73+
[homepage]: https://www.contributor-covenant.org
74+
75+
For answers to common questions about this code of conduct, see
76+
https://www.contributor-covenant.org/faq
77+

CONTRIBUTING.md

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
# SmartSweeper Contribution Guidelines
2+
3+
Thank you for being interested in contributing to the development of SmartSweeper.
4+
5+
## Code of Conduct
6+
7+
We ask that all contributors follow our [code of conduct](CODE_OF_CONDUCT.md). Please report unacceptable behavior to [smartsweeper@swiftlet.technology](mailto:smartsweeper@swiftlet.technology).
8+
9+
## How Can I Contribute?
10+
### Reporting Bugs
11+
12+
1. Please check [existing issues](/issues) to make sure the bug hasn't already been reported. If it has and the issue is still open, please add a new comment to the existing issue.
13+
1. If the bug hasn't been reported, create a new issue by filling in the [bug report template](docs/bug_report.md). Please include as much information as you can.
14+
15+
### Suggesting Enhancements
16+
17+
1. Please check [existing issues](/issues) to make sure that no one else has suggested the same enhancement. If someone has and the issue is still open, please add a new comment to the existing issue.
18+
1. If the suggestion hasn't already been made, please follow [these guidelines](docs/enhancement_suggestion.md).
19+
20+
## Style Guidelines
21+
22+
There are three styles currently in use:
23+
24+
* ```index.js```, ```smartcashapi.js```, and ```rpc-client.js``` more-or-less follow the [Electron style guidelines](https://electronjs.org/docs/development/coding-style)
25+
* The other JavaScript files in general mostly follow the [W3Schools style guide](https://www.w3schools.com/js/js_conventions.asp).
26+
* The file and folder structure in ```/app``` follows the [John Papa's Angular 1 style guide](https://github.com/johnpapa/angular-styleguide/blob/master/a1/README.md).
27+
28+
Going forward, all JavaScript will use the W3Schools style with an exception:
29+
* Conditionals:
30+
```javascript
31+
if (time < 20) {
32+
greeting = "Good day";
33+
}
34+
else {
35+
greeting = "Good evening";
36+
}
37+
```
38+
39+
This guide was inspired by the [Atom contribution guidelines](https://github.com/atom/atom/blob/master/CONTRIBUTING.md).

README.md

Lines changed: 20 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -22,29 +22,32 @@ Sweeper application for [SmartCash cryptocurrency](http://smartcash.cc) to allow
2222
* [Configuration](#configuration)
2323
* [Known issues](#known-issues)
2424
* [Other software used](#other-software-used)
25+
* [Contributing to SmartSweeper development](#contributing)
2526

2627

27-
### Installation
28+
## Installation
2829
Download a release and run the installer. You may need to run SmartSweeper as an administrator.
2930

30-
### Running from source
31-
##### Additional Requirements
31+
32+
## Running from source
33+
#### Additional Requirements
3234
* [Node.js](http://nodejs.org) - 8.9.0+
3335
* [npm](http://npmjs.com) - 5.6.0+
3436

3537
Run ```node -v``` and ```npm -v``` from a command prompt to make sure both are in your PATH. Open your SmartCash node client to make sure it is synchronized before launching SmartSweeper.
3638

37-
##### Installation
39+
#### Installation
3840
``` bash
3941
npm install
4042
```
4143

42-
##### To run
44+
#### To run
4345
``` bash
4446
npm start
4547
```
4648

47-
### Configuration
49+
50+
## Configuration
4851
SmartSweeper can be configured by modifying .env in the root directory. The app will create it for you the first time you load it, but you can create the file yourself prior to that, which will help if you didn't use the default SmartCash installation path. The default values for Windows are shown below.
4952
```
5053
rpc.host=127.0.0.1
@@ -83,7 +86,7 @@ rpcpassword=rpcpassword
8386
The values of rpc.host, rpc.port, rpc.username, and rpc.password in .env must match those in the program arguments or the smartcash.conf file.
8487

8588

86-
##### User files
89+
#### User files
8790
The database (smart-sweeper.json), the app config file (smart-sweeper-config.json), the saved dashboard data file (smart-sweeper-data.json) and the log files are saved in the following folder:
8891

8992
* **Windows**: %APPDATA%/SmartSweeper
@@ -92,15 +95,17 @@ The database (smart-sweeper.json), the app config file (smart-sweeper-config.jso
9295

9396
The log files are also in JSON format and can be viewed with a general log viewer such as [glogg](https://github.com/nickbnf/glogg). The user logs record user actions while the system logs record system actions and errors (and includes transaction ids and public keys).
9497

95-
### Known issues
98+
99+
## Known issues
96100
* SmartSweeper may not open the SmartCash Node Client. If smartcash.conf hasn't been modified with the info above, SmartSweeper won't work if the node client is run manually.
97101
* electron-store error "EPERM operation not permitted" sometimes occurs on Windows when reading a config file. SmartSweeper will exit when it does.
98102
* Can't connect to the node client via RPC when it's syncing (SmartSweeper will display the "Can't connect to SmartCash Node Client." error). This will cause some actions to fail and some project data updates to not occur.
99103
* Claimed funds info on the dashboard and the sweep funds page becomes inaccurate after one or more projects have been swept.
100104
* Empty log files are sometimes created in the root SmartSweeper data folder.
101105
* There is lag when entering text into input fields.
102106

103-
### Other software used
107+
108+
## Other software used
104109
Software | License
105110
-------- | --------
106111
[AngularJS](http://angularjs.org) | MIT
@@ -130,6 +135,10 @@ Software | License
130135

131136
[The SmartCash Insight Explorer](https://insight.smartcash.cc) is used to check the current block count and to get information about project addresses.
132137

133-
## Icons and graphics
138+
### Icons and graphics
134139
* Basic app icons: [Font Awesome](http://fontawesome.io)
135-
* Progress spinner: [preloaders.net](https://preloaders.net)
140+
* Progress spinner: [preloaders.net](https://preloaders.net)
141+
142+
143+
## Contributing
144+
You can [contribute to the development of SmartSweeper](CONTRIBUTING.md) by filing a bug report or by submitting a pull request. All contributors must follow our [code of conduct](docs/CODE_OF_CONDUCT.md).

background/background.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,6 @@
2626
let apiCallbackCounter;
2727
let smartcashProg, smartcashPath, smartcash;
2828
let db = new Store({name: "smart-sweeper"});
29-
//global.bgApiCallbackInfo = new Map(); // keeps track of API callback vars per function call
3029

3130
init();
3231

docs/bug_report.md

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
## SmartSweeper Bug Report Template
2+
3+
### Current Behavior
4+
A detailed description of what is currently happening.
5+
6+
### Expected Behavior
7+
A detailed description of what you expected to happen.
8+
9+
### Possible Solution
10+
A detailed description of what you think might fix the bug.
11+
12+
### Steps to Reproduce
13+
1.
14+
2.
15+
3.
16+
4.
17+
etc.
18+
19+
### Screenshots
20+
If applicable, add screenshots to help explain your problem.
21+
22+
### Operating System and SmartSweeper version (please complete the following information):
23+
- OS: [e.g. Windows 7]
24+
- Version [e.g. 0.9.1]
25+
26+
### Additional Information
27+
Add any other information about the problem here.

docs/pull_request_guidelines.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
# SmartSweeper Pull Request Guidelines
2+
3+
**IMPORTANT: Please do not create a pull request (PR) without creating an issue first.**
4+
5+
1. Describe the enhancement
6+
2. Explain why the enhancement is necessary
7+
8+
9+
## How to make enhancements
10+
0. Create a GitHub account (if necessary).
11+
1. Fork then clone the repo (usually the master branch).
12+
2. Make your changes.
13+
3. Click "New pull request" on the homepage of the SmartSweeper repo.
14+
4. Include the following information in the request comment:
15+
* What process did you follow to verify that your change has the desired effects?
16+
* How did you verify that all new functionality works as expected?
17+
* How did you verify that all changed functionality works as expected?
18+
* How did you verify that the change has not introduced any regressions?
19+
* Closes #[Issue #] in order to automatically close the related issue.

smartcashapi.js

Lines changed: 0 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,6 @@ let reqPerMin
1515
global.smartcashCallbackInfo = new Map() // keeps track of API callback vars per function call
1616

1717
function init() {
18-
//reqPerMin = parseInt(60 / global.sharedObject.explorerCheckInterval)
1918
}
2019

2120
/* Generic API callback function. */
@@ -75,22 +74,6 @@ let smartcashCallback = function(resp, functionName, projectInfo, callback = nul
7574
}
7675

7776
callback({type: 'error', msg: resp.msg}, functionName, projectInfo)
78-
79-
/*if (projectInfo.projectName) {
80-
var address = ""
81-
if (projectInfo.address)
82-
address = ", wallet address: " + projectInfo.address
83-
84-
global.sharedObject.sysLogger.error('project ' + projectInfo.projectName + ', functionName' + functionName + ': ' + resp.msg)
85-
}
86-
else if (projectInfo.projectID) {
87-
global.sharedObject.sysLogger.info(functionName + ', project #' + projectInfo.projectID)
88-
}
89-
else {
90-
global.sharedObject.sysLogger.error(functionName + ': ' + resp.msg)
91-
}*/
92-
93-
9477
}
9578
}
9679

0 commit comments

Comments
 (0)