diff --git a/cherry_picker/cherry_picker.py b/cherry_picker/cherry_picker.py
index 66bde15..3e59f39 100755
--- a/cherry_picker/cherry_picker.py
+++ b/cherry_picker/cherry_picker.py
@@ -198,7 +198,7 @@ class CherryPicker:
         cmd = ["git", "config", "--get", f"remote.{self.pr_remote}.url"]
         result = self.run_cmd(cmd, required_real_result=True)
         # implicit ssh URIs use : to separate host from user, others just use /
-        username = result.replace(":", "/").split("/")[-2]
+        username = result.replace(":", "/").rstrip("/").split("/")[-2]
         return username
 
     def get_cherry_pick_branch(self, maint_branch):

diff --git a/cherry_picker/test_cherry_picker.py b/cherry_picker/test_cherry_picker.py
index bffb11d..3a9f670 100644
--- a/cherry_picker/test_cherry_picker.py
+++ b/cherry_picker/test_cherry_picker.py
@@ -343,10 +343,13 @@ def test_get_pr_url(config):
     [
         b"git@github.com:mock_user/cpython.git",
         b"git@github.com:mock_user/cpython",
+        b"git@github.com:mock_user/cpython/",
         b"ssh://git@github.com/mock_user/cpython.git",
         b"ssh://git@github.com/mock_user/cpython",
+        b"ssh://git@github.com/mock_user/cpython/",
         b"https://github.com/mock_user/cpython.git",
         b"https://github.com/mock_user/cpython",
+        b"https://github.com/mock_user/cpython/",
     ],
 )
 def test_username(url, config):

Username detection fails with a trailing slash
I have my remote origin set to ``https://github.com/AA-Turner/cpython/``.

```ps1con
PS> git remote -v
origin  https://github.com/AA-Turner/cpython/ (fetch)
origin  https://github.com/AA-Turner/cpython/ (push)
upstream        https://github.com/python/cpython/ (fetch)
upstream        https://github.com/python/cpython/ (push)
```

``cherry_picker`` runs ``git config --get remote.origin.url``, which returns the above url, and then runs ``username = result.replace(":", "/").split("/")[-2]``. This returns ``cpython``, which means that I have to manually edit the URL on every backport.

``cherry_picker`` should instead trim any trailing slash.

A
cherry_picker/test_cherry_picker.py::test_username[git@github.com:mock_user/cpython/] cherry_picker/test_cherry_picker.py::test_username[ssh://git@github.com/mock_user/cpython/] cherry_picker/test_cherry_picker.py::test_username[https://github.com/mock_user/cpython/]
cherry_picker/test_cherry_picker.py::test_get_base_branch cherry_picker/test_cherry_picker.py::test_get_base_branch_which_has_dashes cherry_picker/test_cherry_picker.py::test_get_base_branch_invalid[backport-22a594a] cherry_picker/test_cherry_picker.py::test_get_base_branch_invalid[prefix-22a594a-2.7] cherry_picker/test_cherry_picker.py::test_get_base_branch_invalid[backport-22a594a-base] cherry_picker/test_cherry_picker.py::test_get_current_branch cherry_picker/test_cherry_picker.py::test_get_full_sha_from_short cherry_picker/test_cherry_picker.py::test_get_author_info_from_short_sha cherry_picker/test_cherry_picker.py::test_sorted_branch[input_branches0-sorted_branches0] cherry_picker/test_cherry_picker.py::test_sorted_branch[input_branches1-sorted_branches1] cherry_picker/test_cherry_picker.py::test_invalid_branches[input_branches0] cherry_picker/test_cherry_picker.py::test_invalid_branches[input_branches1] cherry_picker/test_cherry_picker.py::test_get_cherry_pick_branch cherry_picker/test_cherry_picker.py::test_upstream_name[upstream-None] cherry_picker/test_cherry_picker.py::test_upstream_name[upstream-upstream] cherry_picker/test_cherry_picker.py::test_upstream_name[origin-None] cherry_picker/test_cherry_picker.py::test_upstream_name[origin-origin] cherry_picker/test_cherry_picker.py::test_upstream_name[python-python] cherry_picker/test_cherry_picker.py::test_error_on_missing_remote[None-upstream-None] cherry_picker/test_cherry_picker.py::test_error_on_missing_remote[origin-upstream-upstream] cherry_picker/test_cherry_picker.py::test_error_on_missing_remote[None-origin-None] cherry_picker/test_cherry_picker.py::test_error_on_missing_remote[upstream-origin-origin] cherry_picker/test_cherry_picker.py::test_error_on_missing_remote[origin-python-python] cherry_picker/test_cherry_picker.py::test_error_on_missing_remote[None-python-None] cherry_picker/test_cherry_picker.py::test_get_pr_url cherry_picker/test_cherry_picker.py::test_username[git@github.com:mock_user/cpython.git] cherry_picker/test_cherry_picker.py::test_username[git@github.com:mock_user/cpython] cherry_picker/test_cherry_picker.py::test_username[ssh://git@github.com/mock_user/cpython.git] cherry_picker/test_cherry_picker.py::test_username[ssh://git@github.com/mock_user/cpython] cherry_picker/test_cherry_picker.py::test_username[https://github.com/mock_user/cpython.git] cherry_picker/test_cherry_picker.py::test_username[https://github.com/mock_user/cpython] cherry_picker/test_cherry_picker.py::test_get_updated_commit_message cherry_picker/test_cherry_picker.py::test_get_updated_commit_message_without_links_replacement cherry_picker/test_cherry_picker.py::test_is_cpython_repo cherry_picker/test_cherry_picker.py::test_is_not_cpython_repo cherry_picker/test_cherry_picker.py::test_find_config cherry_picker/test_cherry_picker.py::test_find_config_not_found cherry_picker/test_cherry_picker.py::test_find_config_not_git cherry_picker/test_cherry_picker.py::test_load_full_config cherry_picker/test_cherry_picker.py::test_load_partial_config cherry_picker/test_cherry_picker.py::test_load_config_no_head_sha cherry_picker/test_cherry_picker.py::test_normalize_long_commit_message cherry_picker/test_cherry_picker.py::test_normalize_short_commit_message cherry_picker/test_cherry_picker.py::test_get_updated_commit_message_with_trailers[Fix cherry_picker/test_cherry_picker.py::test_from_git_rev_read_negative[/some/path/without/revision] cherry_picker/test_cherry_picker.py::test_from_git_rev_read_negative[HEAD:some/non-existent/path] cherry_picker/test_cherry_picker.py::test_from_git_rev_read_uncommitted cherry_picker/test_cherry_picker.py::test_from_git_rev_read cherry_picker/test_cherry_picker.py::test_states cherry_picker/test_cherry_picker.py::test_paused_flow cherry_picker/test_cherry_picker.py::test_start_end_states[fetch_upstream-Workflow cherry_picker/test_cherry_picker.py::test_start_end_states[checkout_default_branch-Workflow cherry_picker/test_cherry_picker.py::test_start_end_states[checkout_previous_branch-Workflow cherry_picker/test_cherry_picker.py::test_cleanup_branch cherry_picker/test_cherry_picker.py::test_cleanup_branch_checkout_previous_branch cherry_picker/test_cherry_picker.py::test_cleanup_branch_fail cherry_picker/test_cherry_picker.py::test_cleanup_branch_checkout_fail cherry_picker/test_cherry_picker.py::test_cherry_pick cherry_picker/test_cherry_picker.py::test_cherry_pick_fail cherry_picker/test_cherry_picker.py::test_get_state_and_verify_fail cherry_picker/test_cherry_picker.py::test_push_to_remote_fail cherry_picker/test_cherry_picker.py::test_push_to_remote_interactive cherry_picker/test_cherry_picker.py::test_push_to_remote_botflow cherry_picker/test_cherry_picker.py::test_push_to_remote_no_auto_pr cherry_picker/test_cherry_picker.py::test_backport_no_branch cherry_picker/test_cherry_picker.py::test_backport_cherry_pick_fail cherry_picker/test_cherry_picker.py::test_backport_cherry_pick_crash_ignored cherry_picker/test_cherry_picker.py::test_backport_cherry_pick_branch_already_exists cherry_picker/test_cherry_picker.py::test_backport_success cherry_picker/test_cherry_picker.py::test_backport_pause_and_continue[True-True] cherry_picker/test_cherry_picker.py::test_backport_pause_and_continue[True-False] cherry_picker/test_cherry_picker.py::test_backport_pause_and_continue[False-True] cherry_picker/test_cherry_picker.py::test_backport_pause_and_continue[False-False] cherry_picker/test_cherry_picker.py::test_continue_cherry_pick_invalid_state cherry_picker/test_cherry_picker.py::test_continue_cherry_pick_invalid_branch cherry_picker/test_cherry_picker.py::test_abort_cherry_pick_invalid_state cherry_picker/test_cherry_picker.py::test_abort_cherry_pick_success cherry_picker/test_cherry_picker.py::test_cli_invoked