You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Nov 9, 2018. It is now read-only.
First off, thank you for considering contributing to USB Canary.
4
+
5
+
### 1. Where do I go from here?
6
+
7
+
If you've noticed a bug or have a question [search the issue tracker](https://github.com/probablynotablog/usb-canary/issues?q=something)
8
+
to see if someone else in the community has already created a ticket. If not, go ahead and [make one](https://github.com/probablynotablog/usb-canary/issues/new)!
9
+
10
+
### 2. Fork & create a branch
11
+
12
+
If this is something you think you can fix, then [fork USB Canary](https://help.github.com/articles/fork-a-repo)
13
+
and create a branch with a descriptive name.
14
+
15
+
A good branch name would be (where issue #325 is the ticket you're working on):
16
+
17
+
```sh
18
+
git checkout -b 325-add-windows-support
19
+
```
20
+
21
+
#### 3. Did you find a bug?
22
+
23
+
***Ensure the bug was not already reported** by searching on GitHub under [Issues](https://github.com/probablynotablog/usb-canary/issues).
24
+
25
+
* If you're unable to find an open issue addressing the problem, [open a new one](https://github.com/probablynotablog/usb-canary/issues/new).
26
+
Be sure to include a **title and clear description**, as much relevant information as possible - use the relevant bug report templates to create the issue.
27
+
28
+
### 5. Implement your fix or feature
29
+
30
+
At this point, you're ready to make your changes! Feel free to ask for help; everyone is a beginner at first.
31
+
32
+
### 6. Test your changes
33
+
34
+
We don't currently have an automated test suite, so it's up to you to test your bug fix or feature to ensure it does not impact exsisting features, unless that feature was really a bug and you're fixing it. If you're unable to test your new feature, reach out to one of the maintainers who will be happy to help. (It may take longer to be accepted)
35
+
36
+
### 7. Make a Pull Request
37
+
38
+
At this point, you should switch back to your master branch and make sure it's
39
+
up to date with USB Canary's master branch.
40
+
41
+
Push it!
42
+
43
+
Finally, go to GitHub and [make a Pull Request](https://help.github.com/articles/creating-a-pull-request).
Copy file name to clipboardExpand all lines: README.md
+17-19Lines changed: 17 additions & 19 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -10,13 +10,15 @@ There are a couple of 3rd party libraries to get USB canary running - for some t
10
10
-[slackclient](https://github.com/slackapi/python-slackclient) - A basic client for Slack.com, which can optionally connect to the Slack Real Time Messaging (RTM) API.
11
11
-[twilio](https://github.com/twilio/twilio-python) - A Python module for communicating with the Twilio API and generating TwiML
12
12
-[pyudev](https://github.com/pyudev/pyudev) - Python bindings to libudev (with support for PyQt4, PySide, pygobject and wx)
13
+
-[sander-daemon](https://github.com/serverdensity/python-daemon) - Jejik daemon class improved by Server Density
13
14
14
15
These can all be installed via `pip`, in some cases you may need to use `pip` with `sudo`. You can install the packages as follows:
15
16
16
17
```
17
18
pip install slackclient
18
19
pip install twilio
19
20
pip install pyudev
21
+
pip install sander-daemon
20
22
```
21
23
22
24
Otherwise you can just run `pip install -r requirements.txt`
@@ -61,23 +63,23 @@ An example `settings.json` file:
61
63
62
64
Note that `paranoid`, `slack`, and `twilio` are boolean values and should be set to `true` or `false`. If the file is formatted incorrectly and it cannot be parsed, you will get a `ValueError`, you can use [JSONLint](http://jsonlint.com/) if you find yourself having issues with this.
63
65
64
-
USB Canary, is sort of smart and can 'detect' if you are running `XScreenSaver` or `gnome-screensaver` on your
65
-
computer, this is done by just checking which packages are installed via the `apt` library, if both of them are
66
-
installed though, it will leave you to determine which one you are using - if you have an unsupported
67
-
screensaver, don't fret, you can still run it in paranoid mode.
66
+
USB Canary, is sort of smart and can 'detect' if you are running `XScreenSaver` or `gnome-screensaver` on your
67
+
computer, this is done by just checking which packages are installed via the `apt` library, if both of them are
68
+
installed though, it will leave you to determine which one you are using - if you have an unsupported
69
+
screensaver, don't fret, you can still run it in paranoid mode.
68
70
69
-
Paranoid mode is also suitable for people who want to monitor if their servers have had USB's plugged into them,
70
-
although I haven't tested them on Linode, Amazon Web Services, or Digital Ocean it is suitable for those with
71
-
physical servers that may need this sort of monitoring.
71
+
Paranoid mode is also suitable for people who want to monitor if their servers have had USB's plugged into them,
72
+
although I haven't tested them on Linode, Amazon Web Services, or Digital Ocean it is suitable for those with
73
+
physical servers that may need this sort of monitoring.
72
74
73
-
To start the application:
74
-
```shell
75
+
To start the application:
76
+
```shell
75
77
./usb_canary.py start | stop | restart
76
78
```
77
79
78
80
## Deployment
79
81
The following will outline the basic steps to deploying USB Canary to Slack and Twilio. As extra services are
80
-
supported, please ensure you add appropriate documentation.
82
+
added, please ensure you add appropriate documentation with your PR.
81
83
82
84
### Twilio
83
85
To use the Twilio intergration you will need to get an:
@@ -107,9 +109,6 @@ usb-canary
107
109
├──LICENSE.txt
108
110
├──settings.json
109
111
├──canary
110
-
│ ├──daemon
111
-
│ │ ├──__init__.py
112
-
│ │ └──daemon.py
113
112
│ ├──slack
114
113
│ │ ├──slack.py
115
114
│ │ ├──slack_bot.py
@@ -128,6 +127,8 @@ usb-canary
128
127
│ └──__init__.py
129
128
├──README.md <---------------------------------- YOU ARE HERE
130
129
├──requirements.txt
130
+
├──ISSUE_TEMPLATE.md
131
+
├──PULL_REQUEST_TEMPLATE.md
131
132
└──usb_canary.py
132
133
```
133
134
Under the main `canary` directory you will find folders for different services such as Twilio which is named `twilleo`
@@ -141,14 +142,11 @@ Screensaver having their own file, just to keep things tidy.
141
142
-[slackclient](https://github.com/slackapi/python-slackclient) - A basic client for Slack.com, which can optionally connect to the Slack Real Time Messaging (RTM) API.
142
143
-[twilio](https://github.com/twilio/twilio-python) - A Python module for communicating with the Twilio API and generating TwiML
143
144
-[python-apt](https://apt.alioth.debian.org/python-apt-doc/library/index.html) - A library that provides access to almost every functionality supported by the underlying apt-pkg and apt-inst libraries
145
+
-[sander-daemon](https://github.com/serverdensity/python-daemon) - Jejik daemon class improved by Server Density
144
146
145
147
## Contributing
146
148
147
-
1. Fork it!
148
-
2. Create your feature branch: `git checkout -b my-new-feature`
149
-
3. Commit your changes: `git commit -am 'Add some feature'`
150
-
4. Push to the branch: `git push origin my-new-feature`
151
-
5. Submit a pull request
149
+
See the [CONTRIBUTING.md](CONTRIBUTING.md) file for details.
152
150
153
151
## Versioning
154
152
@@ -167,4 +165,4 @@ This project is licensed under the GNU GPLv3 License - see the [LICENSE.txt](LIC
167
165
168
166
## Acknowledgements
169
167
170
-
-Sander Marechal - I don't know who you are, but you made damonizing this so much easier!
168
+
-[timball](https://github.com/timball) - for recommending `sander-daemon`
0 commit comments