Skip to content

Commit

Permalink
Merge pull request #16 from tigerteufel85/boggy-15/change-slack-depen…
Browse files Browse the repository at this point in the history
…dency

Change dependency for Slack
  • Loading branch information
tigerteufel85 committed Mar 1, 2022
2 parents 343a33c + 6205164 commit fae2248
Show file tree
Hide file tree
Showing 18 changed files with 27 additions and 21 deletions.
2 changes: 1 addition & 1 deletion bot/bot.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ package bot
import (
"context"
"fmt"
"github.com/nlopes/slack"
"github.com/slack-go/slack"
"github.com/tigerteufel85/boggy/client"
"github.com/tigerteufel85/boggy/config"
"strings"
Expand Down
2 changes: 1 addition & 1 deletion bot/command.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ package bot

import (
"context"
"github.com/nlopes/slack"
"github.com/slack-go/slack"
)

// Commands is a wrapper of a list of commands. Only the first matched command will be executed
Expand Down
2 changes: 1 addition & 1 deletion bot/reload.go
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package bot

import (
"github.com/nlopes/slack"
"github.com/slack-go/slack"
"github.com/tigerteufel85/boggy/client"
"time"
)
Expand Down
2 changes: 1 addition & 1 deletion bot/scheduler.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import (
"strings"
"time"

"github.com/nlopes/slack"
"github.com/slack-go/slack"
"gopkg.in/robfig/cron.v2"
)

Expand Down
11 changes: 9 additions & 2 deletions bot/user.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ package bot
import (
"bufio"
"fmt"
"github.com/nlopes/slack"
"github.com/slack-go/slack"
"github.com/tigerteufel85/boggy/client"
"github.com/tigerteufel85/boggy/config"
"log"
Expand Down Expand Up @@ -84,8 +84,15 @@ func (b *Bot) loadChannelsUsersAndProjects(config *config.Config) error {
var cursor string
var channels []slack.Channel
client.Channels = make(map[string]string)

for {
params := slack.GetConversationsParameters{Cursor: cursor, Types: []string{"private_channel", "public_channel"}}
params := slack.GetConversationsParameters{
Limit: 1000,
Cursor: cursor,
ExcludeArchived: true,
Types: []string{"private_channel", "public_channel"},
}

channels, cursor, err = b.slackClient.GetConversations(&params)
if err != nil {
return err
Expand Down
2 changes: 1 addition & 1 deletion client/slack.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ package client

import (
"fmt"
"github.com/nlopes/slack"
"github.com/slack-go/slack"
"github.com/tigerteufel85/boggy/config"
"strings"
)
Expand Down
2 changes: 1 addition & 1 deletion command/admin_add_user.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import (
"os"
"strings"

"github.com/nlopes/slack"
"github.com/slack-go/slack"
"github.com/tigerteufel85/boggy/bot"
)

Expand Down
2 changes: 1 addition & 1 deletion command/admin_remove_user.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import (
"regexp"
"strings"

"github.com/nlopes/slack"
"github.com/slack-go/slack"
"github.com/tigerteufel85/boggy/bot"
)

Expand Down
2 changes: 1 addition & 1 deletion command/help.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import (
"github.com/tigerteufel85/boggy/client"
"strings"

"github.com/nlopes/slack"
"github.com/slack-go/slack"
"github.com/tigerteufel85/boggy/bot"
"regexp"
"sort"
Expand Down
2 changes: 1 addition & 1 deletion command/jira_issue.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ package command

import (
"context"
"github.com/nlopes/slack"
"github.com/slack-go/slack"
"github.com/tigerteufel85/boggy/bot"
"github.com/tigerteufel85/boggy/client"
"github.com/tigerteufel85/boggy/config"
Expand Down
2 changes: 1 addition & 1 deletion command/jira_issues.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ package command

import (
"context"
"github.com/nlopes/slack"
"github.com/slack-go/slack"
"github.com/tigerteufel85/boggy/bot"
"github.com/tigerteufel85/boggy/client"
"github.com/tigerteufel85/boggy/config"
Expand Down
2 changes: 1 addition & 1 deletion command/jira_issues_single.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ package command

import (
"context"
"github.com/nlopes/slack"
"github.com/slack-go/slack"
"github.com/tigerteufel85/boggy/bot"
"github.com/tigerteufel85/boggy/client"
"github.com/tigerteufel85/boggy/config"
Expand Down
2 changes: 1 addition & 1 deletion command/jira_overview.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import (
"github.com/tigerteufel85/boggy/config"
"strings"

"github.com/nlopes/slack"
"github.com/slack-go/slack"
"github.com/tigerteufel85/boggy/bot"
"github.com/tigerteufel85/boggy/utils"
"gopkg.in/andygrunwald/go-jira.v1"
Expand Down
2 changes: 1 addition & 1 deletion command/schedule_add.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import (
"github.com/tigerteufel85/boggy/config"
"strings"

"github.com/nlopes/slack"
"github.com/slack-go/slack"
"github.com/tigerteufel85/boggy/bot"
"github.com/tigerteufel85/boggy/utils"
"gopkg.in/andygrunwald/go-jira.v1"
Expand Down
2 changes: 1 addition & 1 deletion command/schedule_delete.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"fmt"
"github.com/tigerteufel85/boggy/client"

"github.com/nlopes/slack"
"github.com/slack-go/slack"
"github.com/tigerteufel85/boggy/bot"
"strings"
)
Expand Down
2 changes: 1 addition & 1 deletion command/schedule_list.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"github.com/tigerteufel85/boggy/client"

"fmt"
"github.com/nlopes/slack"
"github.com/slack-go/slack"
"github.com/tigerteufel85/boggy/bot"
"strings"
)
Expand Down
5 changes: 2 additions & 3 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ go 1.17

require (
github.com/imdario/mergo v0.3.7
github.com/nlopes/slack v0.5.0
github.com/slack-go/slack v0.10.2
gopkg.in/andygrunwald/go-jira.v1 v1.6.0
gopkg.in/robfig/cron.v2 v2.0.0-20150107220207-be2e0b0deed5
gopkg.in/yaml.v2 v2.2.2
Expand All @@ -13,8 +13,7 @@ require (
require (
github.com/fatih/structs v1.1.0 // indirect
github.com/google/go-querystring v1.0.0 // indirect
github.com/gorilla/websocket v1.4.0 // indirect
github.com/lusis/slack-test v0.0.0-20180109053238-3c758769bfa6 // indirect
github.com/gorilla/websocket v1.4.2 // indirect
github.com/pkg/errors v0.8.1 // indirect
github.com/stretchr/testify v1.3.0 // indirect
github.com/trivago/tgo v1.0.5 // indirect
Expand Down
2 changes: 1 addition & 1 deletion utils/response_layout.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ package utils

import (
"fmt"
"github.com/nlopes/slack"
"github.com/slack-go/slack"
"github.com/tigerteufel85/boggy/config"
"gopkg.in/andygrunwald/go-jira.v1"
"strings"
Expand Down

0 comments on commit fae2248

Please sign in to comment.