Skip to content

Commit 9a2bd4f

Browse files
Dhiraj240satwikkansal
authored andcommitted
Slack Guide
1 parent dea8f6f commit 9a2bd4f

File tree

1 file changed

+45
-31
lines changed

1 file changed

+45
-31
lines changed

slackbot/Readme.md

Lines changed: 45 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -1,48 +1,62 @@
1-
# Slack Bot For Github
2-
3-
This is a typical slack bot which uses Slack API to make the bot into conversation for newbies.
4-
Follow the steps and use @army_brat as prefix for the below commands.
5-
6-
## Note
1+
# Slack Bot For Github Configuration Guide
2+
<!-- Place this tag where you want the button to render. -->
3+
<a class="github-button" href="https://github.com/Dhiraj240/Slack-Test" data-size="large" data-show-count="true" aria-label="Star Dhiraj240/Slack-Test on GitHub">Star</a>
74

5+
It is highly recommended to setup a virtual environment.
6+
You can follow [This link to install virtualenv!](https://virtualenv.pypa.io/en/latest/installation/)
7+
After that typein :
88
```
9-
We are using @army_brat as prefix so that bot can get a notification
10-
```
11-
## New To Opensource
9+
virtualenv <-any environment-name-you-want>
1210
13-
Write ``` @army_brat help ``` and read carefully.
11+
For me i wrote :
12+
virtualenv env
13+
```
1414

15-
###### Type in the commands accordingly:
15+
## Activate your environment
1616

17-
1.Get invitation to our organisation
18-
```
19-
@army_brat invite me
2017
```
21-
2.Before gazing into issues look at our contribution guidelines
18+
env\scripts\activate
2219
```
23-
@army_brat guide me
24-
```
25-
3.Have a look at unassigned issues
20+
As my environment name was ```env``` so i used this prefix with above command.
21+
For you it can be anything :+1:
22+
23+
## Install requirements
24+
2625
```
27-
@army_brat issues available
26+
pip install -r requirements.txt
2827
```
29-
4.Else create a new issue
28+
29+
## Set Slack Bot Token
30+
3031
```
31-
@army_brat create issue
32-
or
33-
/github open owner/repository
32+
set SLACK_BOT_TOKEN=xxxxxxxxx
3433
```
35-
5.Open or Close an existing issue
34+
Here ```xxxxxxxxxx``` is your slack bot token
35+
36+
## Run Below Script
37+
3638
```
37-
/github reopen <issue-link>
38-
or
39-
/github close <issue-link>
39+
python bot_id.py
4040
```
41-
6.Ask any mentor to assign it for you
41+
You will get a ```BOT_ID``` which will be generated automatically by the above script.
42+
43+
## Set BOT ID
44+
4245
```
43-
@army_brat assign issue
46+
set BOT_ID=xxxxx
4447
```
45-
7.Use bot to save or copy what you type
48+
Here ```xxxxx``` is your generated BOT_ID from the above script
49+
50+
## Run Below Script
51+
4652
```
47-
@army_brat copy <write-whatever-you-want>
53+
python army_brat.py
4854
```
55+
56+
## Join Slack And Play with ```@army_brat```
57+
58+
Add this bot to your channel and replace the code accordingly.Then head on to the link [BOT_COMMANDS_TO_BE_EXECUTED_ON_SLACK](https://github.com/Dhiraj240/Slack-Test/blob/master/Guidelines.md)
59+
60+
## Note
61+
62+
###### The commands you are executing must be done in a virtual environment because this project has different dependencies and if you do not follow it, then there may be the case that it can hamper your someother project.

0 commit comments

Comments
 (0)