diff --git a/.github/dependabot.yml b/.github/dependabot.yml deleted file mode 100644 index 973ac417..00000000 --- a/.github/dependabot.yml +++ /dev/null @@ -1,12 +0,0 @@ -version: 2 - -updates: - - package-ecosystem: "cargo" - directory: "/" - schedule: - interval: "weekly" - - - package-ecosystem: "github-actions" - directory: "/" - schedule: - interval: "weekly" diff --git a/.github/workflows/audit.yml b/.github/workflows/audit.yml deleted file mode 100644 index be9d6d98..00000000 --- a/.github/workflows/audit.yml +++ /dev/null @@ -1,20 +0,0 @@ -name: Audit - -on: - workflow_dispatch: - schedule: - - cron: "0 0 * * 1" - -jobs: - audit: - runs-on: ubuntu-latest - - steps: - - uses: actions/checkout@v4 - - uses: actions-rs/install@master - with: - crate: cargo-audit - - - uses: actions-rs/audit-check@v1 - with: - token: ${{ secrets.GITHUB_TOKEN }} diff --git a/.github/workflows/status_embed.yml b/.github/workflows/status_embed.yml deleted file mode 100644 index 169775e7..00000000 --- a/.github/workflows/status_embed.yml +++ /dev/null @@ -1,72 +0,0 @@ -name: Status Embed - -on: - workflow_run: - workflows: - - CI - types: - - completed - -jobs: - status_embed: - # We send the embed in the following situations: - # - Always after the `CI` workflow, as it runs at the - # end of our workflow sequence regardless of status. - # - Always for the `pull_request` event, as it only - # runs one workflow. - # - Always run for non-success workflows, as they - # terminate the workflow sequence. - if: >- - (github.event.workflow_run.name == 'CI' && github.event.workflow_run.conclusion != 'skipped') || - github.event.workflow_run.event == 'pull_request' || - github.event.workflow_run.conclusion == 'failure' || - github.event.workflow_run.conclusion == 'cancelled' - name: Send Status Embed to Discord - runs-on: ubuntu-latest - - steps: - # A workflow_run event does not contain all the information - # we need for a PR embed. That's why we upload an artifact - # with that information in the Lint workflow. - - name: Get Pull Request Information - id: pr_info - if: github.event.workflow_run.event == 'pull_request' - run: | - curl -s -H "Authorization: token $GITHUB_TOKEN" ${{ github.event.workflow_run.artifacts_url }} > artifacts.json - DOWNLOAD_URL=$(cat artifacts.json | jq -r '.artifacts[] | select(.name == "pull-request-payload") | .archive_download_url') - [ -z "$DOWNLOAD_URL" ] && exit 1 - wget --quiet --header="Authorization: token $GITHUB_TOKEN" -O pull_request_payload.zip $DOWNLOAD_URL || exit 2 - unzip -p pull_request_payload.zip > pull_request_payload.json - [ -s pull_request_payload.json ] || exit 3 - echo "::set-output name=pr_author_login::$(jq -r '.user.login // empty' pull_request_payload.json)" - echo "::set-output name=pr_number::$(jq -r '.number // empty' pull_request_payload.json)" - echo "::set-output name=pr_title::$(jq -r '.title // empty' pull_request_payload.json)" - echo "::set-output name=pr_source::$(jq -r '.head.label // empty' pull_request_payload.json)" - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - - # Send an informational status embed to Discord instead of the - # standard embeds that Discord sends. This embed will contain - # more information and we can fine tune when we actually want - # to send an embed. - - name: GitHub Actions Status Embed for Discord - uses: SebastiaanZ/github-status-embed-for-discord@main - with: - # Our GitHub Actions webhook - webhook_id: ${{ secrets.DISCORD_WEBHOOK_ID }} - webhook_token: ${{ secrets.DISCORD_WEBHOOK_TOKEN }} - - # Workflow information - workflow_name: ${{ github.event.workflow_run.name }} - run_id: ${{ github.event.workflow_run.id }} - run_number: ${{ github.event.workflow_run.run_number }} - status: ${{ github.event.workflow_run.conclusion }} - actor: ${{ github.actor }} - repository: ${{ github.repository }} - ref: ${{ github.ref }} - sha: ${{ github.event.workflow_run.head_sha }} - - pr_author_login: ${{ steps.pr_info.outputs.pr_author_login }} - pr_number: ${{ steps.pr_info.outputs.pr_number }} - pr_title: ${{ steps.pr_info.outputs.pr_title }} - pr_source: ${{ steps.pr_info.outputs.pr_source }} diff --git a/Cargo.lock b/Cargo.lock index 326429c9..13889481 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -243,9 +243,9 @@ dependencies = [ [[package]] name = "clap" -version = "4.5.7" +version = "4.5.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5db83dced34638ad474f39f250d7fea9598bdd239eaced1bdf45d597da0f433f" +checksum = "35723e6a11662c2afb578bcf0b88bf6ea8e21282a953428f240574fcc3a2b5b3" dependencies = [ "clap_builder", "clap_derive", @@ -253,9 +253,9 @@ dependencies = [ [[package]] name = "clap_builder" -version = "4.5.7" +version = "4.5.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f7e204572485eb3fbf28f871612191521df159bc3e15a9f5064c66dba3a8c05f" +checksum = "49eb96cbfa7cfa35017b7cd548c75b14c3118c98b423041d70562665e07fb0fa" dependencies = [ "anstream", "anstyle", @@ -265,9 +265,9 @@ dependencies = [ [[package]] name = "clap_derive" -version = "4.5.5" +version = "4.5.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c780290ccf4fb26629baa7a1081e68ced113f1d3ec302fa5948f1c381ebf06c6" +checksum = "5d029b67f89d30bbb547c89fd5161293c0aec155fc691d7924b64550662db93e" dependencies = [ "heck", "proc-macro2", diff --git a/renovate.json b/renovate.json new file mode 100644 index 00000000..81e79847 --- /dev/null +++ b/renovate.json @@ -0,0 +1,7 @@ +{ + "$schema": "https://docs.renovatebot.com/renovate-schema.json", + "extends": ["config:recommended"], + "prHourlyLimit": 0, + "commitBodyTable": true, + "rebaseWhen": "behind-base-branch" +} diff --git a/src/emotes/downloader.rs b/src/emotes/downloader.rs index dcfdc4e9..6b470514 100644 --- a/src/emotes/downloader.rs +++ b/src/emotes/downloader.rs @@ -475,7 +475,7 @@ pub async fn get_twitch_emote(name: &str) -> Result<()> { let res = if res.is_err() { client - .get(&url.replace("animated", "static")) + .get(url.replace("animated", "static")) .send() .await? .error_for_status() diff --git a/src/handlers/app.rs b/src/handlers/app.rs index 2ce2e58d..fd83361d 100644 --- a/src/handlers/app.rs +++ b/src/handlers/app.rs @@ -178,7 +178,7 @@ impl App { self.components.chat.scroll_offset.jump_to(0); } - pub fn purge_user_messages(&mut self, user_id: &str) { + pub fn purge_user_messages(&self, user_id: &str) { let messages = self .messages .borrow_mut() @@ -190,7 +190,7 @@ impl App { self.messages.replace(messages); } - pub fn remove_message_with(&mut self, message_id: &str) { + pub fn remove_message_with(&self, message_id: &str) { let index = self .messages .borrow_mut() @@ -217,7 +217,7 @@ impl App { } #[allow(dead_code)] - pub fn rotate_theme(&mut self) { + pub fn rotate_theme(&self) { todo!("Rotate through different themes") } }