upleb.uk

Public git repos — served from a NIP-34 GRASP relay at git.upleb.uk

summaryrefslogtreecommitdiff
path: root/src
AgeCommit message (Collapse)Author
2024-08-05fix(remote): `push` when server is ahead of nostrDanConwayDev
but behind local. correctly report on situation and allow push
2024-08-05feat(remote): print git url short nameDanConwayDev
instead of the full url so messages are easier to read
2024-08-05feat(remote): improve `list` warning copyDanConwayDev
so it is clearer and easier to read
2024-08-05feat(remote): improve `push` warning copyDanConwayDev
so it is clearer and easier to read
2024-08-05feat(remote): `push` handle out-of-sync serversDanConwayDev
1. don't attempt to push to a remote which is already up-to-date 2. don't attempt to delete branch on remote if it is already deleted 3. only push when out of sync if remote tip is ancestor of pushed commit 4. force push to remote if user force pushed and remote is in sync with nostr
2024-08-05refactr(remote) `list` abstract `list_from_remotes`DanConwayDev
In preparation for its reuse within `push`
2024-08-02feat(remote): `list` add git server statusDanConwayDev
so we have a status update and know which server is slow
2024-08-02feat(remote): improve warning copyDanConwayDev
so it is more concise and clear
2024-08-02feat(remote): warn when out of syncDanConwayDev
with git servers. this will also form the basis of preventing failed pushes
2024-08-02fix: identifer in parse `nostr://npub/identifer`DanConwayDev
as it was hardcoded to test value
2024-08-01Revert "refactor: fix `stderr` ~> `stdout`"DanConwayDev
This reverts commit 3d2e031294b467be725a4ac5f5e65e029d25699a.
2024-08-01fix(remote): display nostr fetch reportDanConwayDev
use stderr to write lines that get displayed when run as a git-remote-helper
2024-08-01Revert "fix(remote): display nostr fetch report"DanConwayDev
This reverts commit 6b63f150ba9e7c69bf83bcbd24543051c765c9f6.
2024-08-01fix(remote): display nostr fetch reportDanConwayDev
use `stderr` to write lines that get displayed when run as a git-remote-helper
2024-08-01refactor: fix `stderr` ~> `stdout`DanConwayDev
as `stderr` is being used when it shouldn't be
2024-08-01Revert "clear 'fetching updates..' when done"DanConwayDev
This reverts commit 4a38d5f4179114fce60f84c4694284a49f648c64.
2024-08-01clear 'fetching updates..' when doneDanConwayDev
unless there were errors and detailed report doesnt clear
2024-08-01test(remote): fix url `from_naddr`DanConwayDev
as rust-nostr doesn't add trailing slash to relays
2024-08-01feat(remote): `--version` get from cargo packageDanConwayDev
instead of manually set. aligns with ngit version.
2024-08-01feat(remote): add `nostr://npub/identifer`DanConwayDev
support with optional relays as query parameter
2024-08-01test(remote): add nostr url parse testDanConwayDev
in prep for supporting new format
2024-08-01feat(remote): `fetch` fallsback to other serversDanConwayDev
listed in the announcement `clone` tag
2024-08-01feat(remote): `push` to all `clone` serversDanConwayDev
initially we push to the first server, if successful update the state event, then siliently push to the others and silently fail
2024-08-01fix(remote): download oids not refstrDanConwayDev
so that if the git server is ahead of the state announcement, only the commits in the state annoucement will be downloaded
2024-08-01feat(remote): `fetch` uses state eventDanConwayDev
and falls back to git server is state event cant be found
2024-07-31fix(remote): updating `push` state eventDanConwayDev
ensure refs are included in state event use `HashMap` to improve `RepoState` struct
2024-07-31feat(remote): `push` issues state eventDanConwayDev
if no previous state events can be found it replicates git server otherwise it just updates pushed value
2024-07-30refactor: add struct `RepoState`DanConwayDev
to more easily access state details
2024-07-30refactor(remote): improve readabilityDanConwayDev
and move code identifying git server url into `list`, `fetch` and `push`.
2024-07-29refactor(remote): abstract `list`DanConwayDev
in preparation for managing state via nostr
2024-07-29feat(fetch): fetch state announcementsDanConwayDev
if multiple maintainers produce state events with the same timestamp, the event with the largest event_id will be used
2024-07-28fix(remote): only update ref when `push` succeedsDanConwayDev
only update remote ref when push was successful
2024-07-28refactor(remote): abstract `fetch` and `push`DanConwayDev
so main doesn't grow too large
2024-07-28feat(remote): report on `push`DanConwayDev
pass outcome back to git to enable reporting
2024-07-28feat(remote): batch `push` and `fetch`DanConwayDev
requests so that the git_server is called once rather than many time in serial
2024-07-28refactor(remote): allow more `push` callbacksDanConwayDev
by using GitAuthenticatior credential callback directly rather than its `push` method
2024-07-26fix(remote): push updates remote refsDanConwayDev
push was not updating remote refs after the anon remote was being pushed
2024-07-26fix(remote): authenticate pushesDanConwayDev
in the future we could implement our own credentials callback function to remove the dependancy
2024-07-26feat(remote): add nostr git remote helperDanConwayDev
as a simple proxy to the first git server listed in announcement parse clone url as `nostr://naddr123...`
2024-07-25fix(init): add missing identifier to yamlDanConwayDev
add missing or updated identifier to maintainers.yaml as we were not checking whether it has changed or added also update if relays do not match
2024-07-24refactor: use nip34 kinds from rust-nostrDanConwayDev
instead of Kind::Custom(u16) as v33 of rust-nostr introduced them
2024-07-24feat(push): `--force` tries non-interactivelyDanConwayDev
if branch is ahead of main or master
2024-07-23feat(list): unique proposal branch namesDanConwayDev
to prevent accidental name conflicts. also moved to prs/* namespace `pull` and `push` integration tests are intermitantly failing to end at least for `push` they work when run individually but not when run together
2024-07-22fix: typos and improve copyDanConwayDev
when finding repo announcements add a hint to find naddr on gitworkshop.dev
2024-07-22chore: bump rust-nostr to v0.33.0DanConwayDev
bump all rust-nostr packages move from using patched nip46 nip05 function to profile function in v33 fix send_events_to error message
2024-07-22fix(pull): find proposal, root not revisionDanConwayDev
when looking for proposal roots 'pull' was not filtering out proposal revisions issue identified in failing test, which it now passes
2024-07-19feat: intergrate `fetch` into `init`DanConwayDev
as part of a project to use fetch and the stored cache everywhere
2024-07-19feat: save created events to cacheDanConwayDev
as soon as they are successfully sent to at least one relay
2024-07-19feat: integrate `fetch` into `list`DanConwayDev
as part of a project to use fetch and the stored cache everywhere
2024-07-19feat: integrate `fetch` into `pull`DanConwayDev
the last set of pull integration test fails: when_latest_event_rebases_branch we are planning on replacing pull so I'm not sure whether it is worth fixing
2024-07-19feat: integrate `fetch` into `push`DanConwayDev
as part of a project to use `fetch` and the stored cache everywhere
2024-07-19feat(send): add relay hints to linkDanConwayDev
to proposal which is displayed at the end of the functon
2024-07-19feat: intergrate `fetch` into `send`DanConwayDev
reworking the tests and test suite as appropriate
2024-07-19fix(fetch): error when user profile not presentDanConwayDev
when fetching a user profile from user relays it throw an error when an existing version of the profile wasn't found
2024-07-19fix(fetch): absent repo addr infinite loopDanConwayDev
prevent an infinite loop when a new maintainer is identified that hasn't issued a repo event yet make it clear when repo_coordinates must not have relays
2024-07-18fix(fetch): dont report old profile as updateDanConwayDev
as any profile event was being recorded as a update
2024-07-18fix(fetch): get profiles of fresh contributorsDanConwayDev
rather than ending the loop without fetching them
2024-07-18fix(fetch): new coodinates infinite loopDanConwayDev
prevent infinite loop when new coordinates are found
2024-07-18refactor(fetch): move database cacheDanConwayDev
into cache directory rather than config directories also removed CodeCollaboration from path as this isn't helpful whilst this is a breaking change, the cache was only introduced during development of this version so it is not highlighted as such
2024-07-18fix(fetch): report profile updates as updatesDanConwayDev
rather than as new profiles
2024-07-18improve copyDanConwayDev
add a message for the temporary situation where a maintainers.yaml exists without an identifier listed
2024-07-18refactor: fetch some profiles from user relaysDanConwayDev
add the ability to fetch more than just the current user from their user write relays
2024-07-18fix(fetch): find repo based in naddr relay hintDanConwayDev
which will enable the following`list` test to pass once `fetch` is intergrated into `list`: finds_based_on_naddr_on_embeded_relay
2024-07-17fix(fetch): get profile with nsec cli parameterDanConwayDev
only the profile from the saved user was being fetched. tests are using cli login parameters and expecting to see the user's name but it was only showing the npub. fixed by allowing the explicit request of specfic user profiles.
2024-07-17feat(init): set repo pointer in git configDanConwayDev
set repo.nostr to naddr reflecting the announcement just issued
2024-07-17feat(login): use fetch to get user profileDanConwayDev
fetch automatically gets updates to logged in user profile / relays fetching without specifying repo pointers will just fetch user profiles so that can be used during login, if user profile isn't in cache login now uses fetch
2024-07-16feat(fetch): get contributor profilesDanConwayDev
just from repository / fallback relays and only if we don't already have a version in cache this is because we are only using it for the user's name
2024-07-16fix(fetch): report grammar and copyDanConwayDev
as 'fetching... updates:' feels more like further updates are being fetched than 'fetching... found'
2024-07-16fix(fetch): report detailsDanConwayDev
so it only counts commits and statues to existing proposals
2024-07-16feat(fetch): search newly discovered inbox relaysDanConwayDev
to increase the likelihood that all events are found
2024-07-16refactor(fetch): improve FetchRequestDanConwayDev
im preparation for identifying new inbox relays
2024-07-15feat(fetch): fetch events and save to cacheDanConwayDev
enabler to add simplicity, efficency and offline capability to other functions improve repo announcement selection
2024-07-05feat(init): group by statusv1.3-beta1DanConwayDev
show open proposal by defult and include options to filter by other statuses there are not tests for this currently as the intention is to transform 'list' further by adding a 'fetch'
2024-07-03fix(login): use saved bunker loginDanConwayDev
a typo prevented fetching of saved bunker-uri and therefore ngit would act as if it wasn't saved
2024-07-03fix(list): remove event size limitDanConwayDev
disable event limits in rust-nostr which cause large patches to be filtered out
2024-07-02fix(repo_ref): fallback to author as maintainerDanConwayDev
if the maintainers tag is omitted
2024-07-02feat(send): tag each maintainer's repo eventDanConwayDev
instead of just tagging the first maintainer's repo event and each maintainer with a p tag This allows for easier discoverability of the proposal when: * the first maintainer hasn't issued a repo event * the maintainers change over time and the single tagged repo event is no listed as a maintainer in anyone elses repo event
2024-06-28feat(login): login with nostr address via nip46DanConwayDev
currently using patched version of rust-nostr with function to fetch nip46 relays from nip05 providers. this patch has been merged so it will make it into the next rust-nostr release.
2024-06-28feat(login): login with nip46 remote signerDanConwayDev
and save details in git config
2024-06-25refactor: replace keys with signerDanConwayDev
so that nip46 bunker signing can be added
2024-06-25test: fix login in testsDanConwayDev
ensure fresh global cache when under test conditions by conditionally storing it in local ./git folder
2024-06-24feat(login): store in git config and use cacheDanConwayDev
replace ngit yaml file config with: * nsec / ncryptsec / npub in git config in nostr.* namespace * sql database cache for metadata and relay events allow different logins to be used for different git repositories by storing login in local git config
2024-06-13feat(git): add get and save git config itemDanConwayDev
local or global but tests only added for local
2024-06-13feat(init): add euc marker to commit referenceDanConwayDev
based on nip34 update. see nip repository commit 8fe6e062254b37f77540088cccff60fa8615751
2024-06-13chore: bump rust-nostr to v0.32.0DanConwayDev
both nostr and nostr-sdk packages and also in test_utils fix the many breaking changes fix: ignore trailing slash when depuplicate relays for send events. this was picked up as TagStandard::RelayMetadata has started adding a traling slash. refactor cli output test function `expect_send_with_progress` so that relays can succeed / fail in a random order
2024-06-11refactor: bump rust-nostr to v0.30 use ncryptsecDanConwayDev
bump nostr and nostr-sdk packages and also in test_utils remove custom ncryptsec implementation and use the newly added implementation nip49 version in rust-nostr note a patched v0.30 is used so that log_n is exposed so that user can be warned it might take a few seconds to decrypt. this has now been merged into the library. note that this will no longer decrypt existing ncryptsec values as it is uses a longer string. this should therefore be bundled with the upcoming change to storing nsec and ncryptsec in git config.
2024-05-23feat: add NIP-31 alt tagsDanConwayDev
to repo announcements, patches and cover letters
2024-05-14fix: `ngit init` multiple maintainersDanConwayDev
fixes: nostr:nevent1qqsz2g7gexkmqgr0x4g5kf9py8vx06p8nyn78v7mhevprasnyfy5swcpp4mhxue69uhkummn9ekx7mqzyr7jprhgeregx7q2j4fgjmjgy0xfm34l63pqvwyf2acsd9q0mynuzdyll0c
2024-05-07feat(send): `in-reply-to` tags npubs and eventsDanConwayDev
in addition to being used to create a new proposal revision, in-reply-to can now be used to reference other events and npubs. for example an issues or kind 1 threads where the proposal is relevant the proposal will only be marked as a revision if the first parameter is a reference to an existing proposal root
2024-04-24fix: remove relay.f7z.io from default relaysDanConwayDev
as over the last 2-3 weeks it has consitantly be timing out
2024-04-22feat(send): print link to proposal rootDanConwayDev
after a new root proposal has been sent link directly to gitworkshop.dev as well as njump.me until gitworkshop is added to njump
2024-04-10feat: reduce connection timeout 6s ~> 3sDanConwayDev
seperate connection timeout from get_events_of timeout and reduce it to 3s
2024-04-08feat(init): support multiple git_serversDanConwayDev
in line with initial merged nip34 spec
2024-04-08feat: reduce `get_events` timeout 10s ~> 6sDanConwayDev
if relays do not connect and retun events within 3s they will rarely connect at all this could be reversed when get_events is used async
2024-03-28refactor: allow pedantic clippy warning large_futuresDanConwayDev
rust-nostr author suggested this might be a false positive https://github.com/rust-nostr/nostr/pull/375#issuecomment-2022245832
2024-03-27fix: relay connection timeout panicDanConwayDev
upgrade from rust-nostr v0.27 ~> v0.28 introduces this panic presumably get_events attempted to write to the MultiProgress just after it has been removed
2024-03-27refactor: more concise error messageDanConwayDev
to suppress the clippy too_many_lines in function warning
2024-03-25update tag generationDanConwayDev
to reflect changes in rust-nostr
2024-03-22replace XOnlyPublicKey with wrapper PublicKeyDanConwayDev
to reflect new name in rust-nostr
2024-03-22rename from_sk_str -> from_strDanConwayDev
to reflect new name in rust-nostr