From dev-return-169830-archive-asf-public=cust-asf.ponee.io@commons.apache.org Tue Feb 12 23:58:13 2019 Return-Path: X-Original-To: archive-asf-public@cust-asf.ponee.io Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by mx-eu-01.ponee.io (Postfix) with SMTP id 7EB39180675 for ; Wed, 13 Feb 2019 00:58:12 +0100 (CET) Received: (qmail 76801 invoked by uid 500); 12 Feb 2019 23:58:06 -0000 Mailing-List: contact dev-help@commons.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "Commons Developers List" Delivered-To: mailing list dev@commons.apache.org Received: (qmail 76788 invoked by uid 99); 12 Feb 2019 23:58:05 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd4-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 12 Feb 2019 23:58:05 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd4-us-west.apache.org (ASF Mail Server at spamd4-us-west.apache.org) with ESMTP id 699AEC1BB2 for ; Tue, 12 Feb 2019 23:58:05 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd4-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 0.6 X-Spam-Level: X-Spam-Status: No, score=0.6 tagged_above=-999 required=6.31 tests=[DKIMWL_WL_MED=-0.001, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, KAM_ASCII_DIVIDERS=0.8, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_PASS=-0.001] autolearn=disabled Authentication-Results: spamd4-us-west.apache.org (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com Received: from mx1-lw-us.apache.org ([10.40.0.8]) by localhost (spamd4-us-west.apache.org [10.40.0.11]) (amavisd-new, port 10024) with ESMTP id ON8J80VLOaL4 for ; Tue, 12 Feb 2019 23:58:03 +0000 (UTC) Received: from mail-pf1-f194.google.com (mail-pf1-f194.google.com [209.85.210.194]) by mx1-lw-us.apache.org (ASF Mail Server at mx1-lw-us.apache.org) with ESMTPS id 5C6EE60E46 for ; Tue, 12 Feb 2019 23:58:03 +0000 (UTC) Received: by mail-pf1-f194.google.com with SMTP id f132so238484pfa.6 for ; Tue, 12 Feb 2019 15:58:03 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to; bh=R/Qf205iXMSKWCU80py8ESO1O2YubdjVFop2eW/GjvA=; b=UT4I2L5K0tDVpus8+3fdWuf+qTzl2Pn6Ypinv7L1ieueqesKpRD/Cpd78fS6xadEKC QPtHU9ROXUZsAiecYEizYwwUjTOcVuOq6M80z3LKrh45KtgQK61w2jw/c5pGAntyCrd6 5UJg/iRlVEQMEeHTzR1Y76T181ygsqrDsGDGnXYvtj6VikckLNElDBYUdWefyPK+YvOW unq3Z35xKKvnICXybpYdnsu3EUJXrG040ifO4FAuStck34NGm5S2R9eTQi5u8jLju2Jx MX31bkpUnGgvBLxOS957qIYygcsFDC2/ipurhVXIDekBG6tKmHX6iNCa+IEh7sIGpL4a qJGg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to; bh=R/Qf205iXMSKWCU80py8ESO1O2YubdjVFop2eW/GjvA=; b=VhYW3tcAxrkIve+DGTx6wM5CW/gyQNx9gCjxzt+UGNwYtTrtwqEEtsf46t5dwVnMe7 ceBKTe6bzUXAamGbVmXJLxcHeoIekLKWGc462SJVO2sYWI/jSHDAqUTijQQnJSG50WaX JI3cCa5EubOg4nlKjOAreuvQjAsu0rCvjZwzHEyFwG81R3TFSYKNiEyjXEJTiM2AyP1b gMDdEHpgMXwpOWtAxIemqFvGI5st7vWeBj5CtBdjZT6vJ/VRAOURg1vKhXYELNCxP6yk hNHvfbmCMS7oC3r0HYjOtjWzn46aYhGyp54663KC3UiiyaTBqTQ2YuaZDRRftEoiKNPe PSwA== X-Gm-Message-State: AHQUAuYnhG6as0pzTuj9eFi3Qbvnk/XgRwLbWJQh0DPT4Qc2JUS9BzCp NtHi739F8dTZNVMAur4FdRc+/m5tPN5mfoDRWFuKhg== X-Google-Smtp-Source: AHgI3Ia9181NTJk9yeZp/MbR+iAiBjL8Mav4ePXN9DtPqE4mvyjtph0T7BtqTw9UMXUBlBvS4yhRJOw+gdQE/ABdn/U= X-Received: by 2002:a62:28c9:: with SMTP id o192mr6624955pfo.57.1550015882146; Tue, 12 Feb 2019 15:58:02 -0800 (PST) MIME-Version: 1.0 References: In-Reply-To: From: sebb Date: Tue, 12 Feb 2019 23:57:50 +0000 Message-ID: Subject: Re: [OT][GIT help] How to restore a branch in a github fork To: Commons Developers List Content-Type: text/plain; charset="UTF-8" On Tue, 12 Feb 2019 at 22:34, Marcelo Vanzin wrote: > > If: > > - you deleted the branch from the remote > > Just push your local branch to the remote. > > - you deleted the branch from the local repo only > > Just checkout the remote branch again. If you had local changes that > are not in the remote, continue below. > > - you deleted the branch from local and it did not exist in the > remote, or you also deleted from the remote Deleted from local and remote. But it still exists in the upstream from which the Github repo was forked That is the branch I want to restore. > Check "git reflog" and see if the commits to the deleted branch still > exist. If they do you can just "checkout" them again. But how do I restore the branch in my Github fork? > - if none of the above applies, well, I think you just lost the code. It is still in the upstream source - that is a 3rd party repo How can I restore it from there? > On Tue, Feb 12, 2019 at 2:29 PM sebb wrote: > > > > I have a github fork of a 3rd party repo. > > > > Unfortunately I deleted a branch for which I wish to provide patches. > > > > Anyone know how to restore/recreate an upstream branch in a Github fork? > > > > I cannot destroy and recreate the fork as it has some outstanding PRs. > > > > I suppose I could create a second fork, but that seems a bit > > unnecessary - if only I could recover the missing branch. > > > > Any Git gurus here? > > > > S. > > > > --------------------------------------------------------------------- > > To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org > > For additional commands, e-mail: dev-help@commons.apache.org > > > > > -- > Marcelo > > --------------------------------------------------------------------- > To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org > For additional commands, e-mail: dev-help@commons.apache.org > --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org For additional commands, e-mail: dev-help@commons.apache.org