'Cross-domain redirects to github repositories from netlify

I have a website on netlify (https://ari-web.netlify.app/) with a custom domain (https://ari-web.xyz/), I want to link a github repo to a route (for example https://ari-web.xyz/git code here/git), I already achieved this in the browser, it works fine and redirects to https://github.com/TruncatedDinosour/website but I would like it to be git-clonable, but it is not and anything I found on it did not work (for example HTTP/302 redirect)

I have access to DNS and can add custom redirects and all that stuff, just whatever netlify allows, you can see the /git route in https://github.com/TruncatedDinosour/website/blob/terminal/netlify.toml#L44...L48

[[redirects]]
from = "/git"
to = "https://github.com/TruncatedDinosour/website"
status = 301
force = true

I found related stuff:

but they did not help

Is it even possible?



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source