Re: Updating sources file using fedpkg

2021-07-02 Thread Sérgio Basto
On Fri, 2021-07-02 at 15:38 -0400, Ken Dreyer wrote:
> On Fri, Jun 18, 2021 at 4:24 AM Vít Ondruch 
> wrote:
> > 
> > I always use `fedpkg import` and this command has `--offline` option,
> > which populates the `sources` file without uploading the archives to
> > the
> > look-a-side cache.
> 
> Oh, nice, I did not know of that command. Thanks.

we got this fresh PR https://pagure.io/rpkg/pull-request/561 
seems to me the most correct . 


Best regards, 
-- 
Sérgio M. B.
___
devel mailing list -- devel@lists.fedoraproject.org
To unsubscribe send an email to devel-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Do not reply to spam on the list, report it: 
https://pagure.io/fedora-infrastructure


Re: Updating sources file using fedpkg

2021-07-02 Thread Ken Dreyer
On Fri, Jun 18, 2021 at 4:24 AM Vít Ondruch  wrote:
>
> I always use `fedpkg import` and this command has `--offline` option,
> which populates the `sources` file without uploading the archives to the
> look-a-side cache.

Oh, nice, I did not know of that command. Thanks.
___
devel mailing list -- devel@lists.fedoraproject.org
To unsubscribe send an email to devel-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Do not reply to spam on the list, report it: 
https://pagure.io/fedora-infrastructure


Re: Updating sources file using fedpkg

2021-06-23 Thread Sérgio Basto
On Tue, 2021-06-22 at 01:03 +0300, Otto Urpelainen wrote:
> Ewoud Kohl van Wijngaarden kirjoitti 21.6.2021 klo 14.50:
> > On Thu, Jun 17, 2021 at 09:02:12PM +0300, Otto Urpelainen wrote:
> > > I am a bit confused about this discussion. My fedpkg does not care 
> > > about the 'sources' file or the lookaside cache at all on 'fedpkg
> > > mockbuild'. It simply looks up the expected filename of downloaded 
> > > Source, grabs it from the local working directory and uses that. So
> > > for me this works:
> > > 
> > >    rpmdev-bumpspec -D -n 1.2.3 *.spec
> > >    # Update specfile as needed
> > >    spectool -g *.spec
> > >    fedpkg mockbuild
> > 
> > Now it also downloads the old files mentioned in sources. In my 
> > experience it certainly does care about it.
> > 
> > Maybe my request can be reduced to: mockbuild should not download
> > files 
> > not mentioned in the spec file. Ken did give a good workaround.
> > Taking 
> > that a step further I think something like this would suffice for me:
> > 
> > spectool -l *.spec | awk '/https?:/ { print $2 }' | xargs -n 1
> > basename 
> > > xargs sha512sum --tag > sources
> 
> Ah, you are right. Since I settled on my current workflow, I did not 
> even notice those useless files being downloaded. I guess I have not 
> encounters are very large one, then.
> 
> I filed an issue about this: https://pagure.io/rpkg/issue/559

I prefer have the offline option on new-sources (1) note if you update
sources files with `sha512sum --tag` (2) you won't have more downloads
of wrong files. 

I'm also interesting on this feature .

Thank you .  


(1)
fedpkg new-sources --offline ${TARBALL_CLEAN} $main_ver $daily_ver
$bytecode_ver

(2)
sha512sum --tag  ${TARBALL_CLEAN} $main_ver $daily_ver $bytecode_ver >
sources 


> Otto
> ___
> devel mailing list -- devel@lists.fedoraproject.org
> To unsubscribe send an email to devel-le...@lists.fedoraproject.org
> Fedora Code of Conduct: 
> https://docs.fedoraproject.org/en-US/project/code-of-conduct/
> List Guidelines: 
> https://fedoraproject.org/wiki/Mailing_list_guidelines
> List Archives: 
> https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
> Do not reply to spam on the list, report it: 
> https://pagure.io/fedora-infrastructure

-- 
Sérgio M. B.
___
devel mailing list -- devel@lists.fedoraproject.org
To unsubscribe send an email to devel-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Do not reply to spam on the list, report it: 
https://pagure.io/fedora-infrastructure


Re: Updating sources file using fedpkg

2021-06-23 Thread Ewoud Kohl van Wijngaarden

On Tue, Jun 22, 2021 at 01:03:54AM +0300, Otto Urpelainen wrote:

Ewoud Kohl van Wijngaarden kirjoitti 21.6.2021 klo 14.50:

On Thu, Jun 17, 2021 at 09:02:12PM +0300, Otto Urpelainen wrote:
I am a bit confused about this discussion. My fedpkg does not care 
about the 'sources' file or the lookaside cache at all on 'fedpkg 
mockbuild'. It simply looks up the expected filename of downloaded 
Source, grabs it from the local working directory and uses that. 
So for me this works:


   rpmdev-bumpspec -D -n 1.2.3 *.spec
   # Update specfile as needed
   spectool -g *.spec
   fedpkg mockbuild


Now it also downloads the old files mentioned in sources. In my 
experience it certainly does care about it.


Maybe my request can be reduced to: mockbuild should not download 
files not mentioned in the spec file. Ken did give a good 
workaround. Taking that a step further I think something like this 
would suffice for me:


spectool -l *.spec | awk '/https?:/ { print $2 }' | xargs -n 1 
basename | xargs sha512sum --tag > sources


Ah, you are right. Since I settled on my current workflow, I did not 
even notice those useless files being downloaded. I guess I have not 
encounters are very large one, then.


I filed an issue about this: https://pagure.io/rpkg/issue/559


Thanks!
___
devel mailing list -- devel@lists.fedoraproject.org
To unsubscribe send an email to devel-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Do not reply to spam on the list, report it: 
https://pagure.io/fedora-infrastructure


Re: Updating sources file using fedpkg

2021-06-21 Thread Otto Urpelainen

Ewoud Kohl van Wijngaarden kirjoitti 21.6.2021 klo 14.50:

On Thu, Jun 17, 2021 at 09:02:12PM +0300, Otto Urpelainen wrote:
I am a bit confused about this discussion. My fedpkg does not care 
about the 'sources' file or the lookaside cache at all on 'fedpkg 
mockbuild'. It simply looks up the expected filename of downloaded 
Source, grabs it from the local working directory and uses that. So 
for me this works:


   rpmdev-bumpspec -D -n 1.2.3 *.spec
   # Update specfile as needed
   spectool -g *.spec
   fedpkg mockbuild


Now it also downloads the old files mentioned in sources. In my 
experience it certainly does care about it.


Maybe my request can be reduced to: mockbuild should not download files 
not mentioned in the spec file. Ken did give a good workaround. Taking 
that a step further I think something like this would suffice for me:


spectool -l *.spec | awk '/https?:/ { print $2 }' | xargs -n 1 basename 
| xargs sha512sum --tag > sources


Ah, you are right. Since I settled on my current workflow, I did not 
even notice those useless files being downloaded. I guess I have not 
encounters are very large one, then.


I filed an issue about this: https://pagure.io/rpkg/issue/559

Otto
___
devel mailing list -- devel@lists.fedoraproject.org
To unsubscribe send an email to devel-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Do not reply to spam on the list, report it: 
https://pagure.io/fedora-infrastructure


Re: Updating sources file using fedpkg

2021-06-21 Thread Ewoud Kohl van Wijngaarden

On Thu, Jun 17, 2021 at 09:02:12PM +0300, Otto Urpelainen wrote:

Ken Dreyer kirjoitti 17.6.2021 klo 19.04:

On Thu, Jun 17, 2021 at 8:33 AM Richard Shaw  wrote:


On Thu, Jun 17, 2021 at 7:22 AM Ewoud Kohl van Wijngaarden 
 wrote:



To be clear: I don't want to fiddle with the sources file, hence this
email. However, I would like to at least complete a local mockbuild
before uploading to the lookaside cache. It is my understanding that
new-sources always does this.



That's actually a nit I've been tempted to complain about. If I'm upgrading a 
package to a new version I update the spec file:

rpmdev-bumpspec -n  -c "Update to ." *.spec

And download the new source:

spectool -g *.spec

But then I have to upload the new source with 'fedpkg new-sources' if I don't 
want it to download the old version.


Yeah, the way I deal with this is I zero out the sources file, like ">
sources". Or another alternative that I use sometimes is "sha512sum
--tag", like:

  sha512sum --tag kstart-4.2.tar.gz > sources


This is really helpful! I did not know it's the output of the --tag 
parameter.




Hi Ewould and everybody,

I am a bit confused about this discussion. My fedpkg does not care 
about the 'sources' file or the lookaside cache at all on 'fedpkg 
mockbuild'. It simply looks up the expected filename of downloaded 
Source, grabs it from the local working directory and uses that. So 
for me this works:


   rpmdev-bumpspec -D -n 1.2.3 *.spec
   # Update specfile as needed
   spectool -g *.spec
   fedpkg mockbuild


Now it also downloads the old files mentioned in sources. In my 
experience it certainly does care about it.


Maybe my request can be reduced to: mockbuild should not download files 
not mentioned in the spec file. Ken did give a good workaround. Taking 
that a step further I think something like this would suffice for me:


spectool -l *.spec | awk '/https?:/ { print $2 }' | xargs -n 1 basename | xargs 
sha512sum --tag > sources

After that is done, the rpm is available at results_mypackage, I 
install it locally and see that everything works. At that point it is 
a good time do 'fedpkg new-sources'.


This I understand.

This also means that non-packagers actually *can* properly test their 
changes. The maintainer has to do new-sources, commit, push and build 
after merging the pull request, so annoyingly there are those steps to 
remember. But at least the pull request author does not have to submit 
their changes blindly.


A simple test to make sure that it really uses the local download:

   $ sed -i 's/^Source.*/Source:https:\/\/example.com\/foo/' *.spec
   $ fedpkg mockbuild
   SOME_OUTPUT
   error: Bad file: SOMEPATH/foo: No such file or directory
   $ touch foo
   $ fedpkg mockbuild
   LOTS_OF_OUTPUT
   SOME_ERROR_DUE_TO_EMPTY_SOURCE

When I started, I was having exactly the same trouble, so wrote 
something in the wiki:


https://fedoraproject.org/wiki/Package_maintenance_guide#Using_fedpkg_anonymously


That's certainly a good start. I'm hoping to remove even more obstackles 
for new contributors.

___
devel mailing list -- devel@lists.fedoraproject.org
To unsubscribe send an email to devel-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Do not reply to spam on the list, report it: 
https://pagure.io/fedora-infrastructure


Re: Updating sources file using fedpkg

2021-06-21 Thread Vít Ondruch


Dne 17. 06. 21 v 20:02 Otto Urpelainen napsal(a):

Ken Dreyer kirjoitti 17.6.2021 klo 19.04:
On Thu, Jun 17, 2021 at 8:33 AM Richard Shaw  
wrote:


On Thu, Jun 17, 2021 at 7:22 AM Ewoud Kohl van Wijngaarden 
 wrote:



To be clear: I don't want to fiddle with the sources file, hence this
email. However, I would like to at least complete a local mockbuild
before uploading to the lookaside cache. It is my understanding that
new-sources always does this.



That's actually a nit I've been tempted to complain about. If I'm 
upgrading a package to a new version I update the spec file:


rpmdev-bumpspec -n  -c "Update to ." *.spec

And download the new source:

spectool -g *.spec

But then I have to upload the new source with 'fedpkg new-sources' 
if I don't want it to download the old version.


Yeah, the way I deal with this is I zero out the sources file, like ">
sources". Or another alternative that I use sometimes is "sha512sum
--tag", like:

   sha512sum --tag kstart-4.2.tar.gz > sources


Hi Ewould and everybody,

I am a bit confused about this discussion. My fedpkg does not care 
about the 'sources' file or the lookaside cache at all on 'fedpkg 
mockbuild'. 



I am not using `fedpkg mockbuild`, but `fedpkg srpm` certainly cares 
about 'sources' file. Prior creating the SRPM, it download files listed 
in 'sources' file from lookaside cache. However, later it uses whatever 
is available in the directory.



Vít


It simply looks up the expected filename of downloaded Source, grabs 
it from the local working directory and uses that. So for me this works:


    rpmdev-bumpspec -D -n 1.2.3 *.spec
    # Update specfile as needed
    spectool -g *.spec
    fedpkg mockbuild

After that is done, the rpm is available at results_mypackage, I 
install it locally and see that everything works. At that point it is 
a good time do 'fedpkg new-sources'.


This also means that non-packagers actually *can* properly test their 
changes. The maintainer has to do new-sources, commit, push and build 
after merging the pull request, so annoyingly there are those steps to 
remember. But at least the pull request author does not have to submit 
their changes blindly.


A simple test to make sure that it really uses the local download:

    $ sed -i 's/^Source.*/Source:https:\/\/example.com\/foo/' *.spec
    $ fedpkg mockbuild
    SOME_OUTPUT
    error: Bad file: SOMEPATH/foo: No such file or directory
    $ touch foo
    $ fedpkg mockbuild
    LOTS_OF_OUTPUT
    SOME_ERROR_DUE_TO_EMPTY_SOURCE

When I started, I was having exactly the same trouble, so wrote 
something in the wiki:


https://fedoraproject.org/wiki/Package_maintenance_guide#Using_fedpkg_anonymously 



Otto
___
devel mailing list -- devel@lists.fedoraproject.org
To unsubscribe send an email to devel-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/

List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Do not reply to spam on the list, report it: 
https://pagure.io/fedora-infrastructure

___
devel mailing list -- devel@lists.fedoraproject.org
To unsubscribe send an email to devel-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Do not reply to spam on the list, report it: 
https://pagure.io/fedora-infrastructure


Re: Updating sources file using fedpkg

2021-06-18 Thread Vít Ondruch
I always use `fedpkg import` and this command has `--offline` option, 
which populates the `sources` file without uploading the archives to the 
look-a-side cache.



Vít


Dne 17. 06. 21 v 18:04 Ken Dreyer napsal(a):

On Thu, Jun 17, 2021 at 8:33 AM Richard Shaw  wrote:

On Thu, Jun 17, 2021 at 7:22 AM Ewoud Kohl van Wijngaarden 
 wrote:


To be clear: I don't want to fiddle with the sources file, hence this
email. However, I would like to at least complete a local mockbuild
before uploading to the lookaside cache. It is my understanding that
new-sources always does this.


That's actually a nit I've been tempted to complain about. If I'm upgrading a 
package to a new version I update the spec file:

rpmdev-bumpspec -n  -c "Update to ." *.spec

And download the new source:

spectool -g *.spec

But then I have to upload the new source with 'fedpkg new-sources' if I don't 
want it to download the old version.

Yeah, the way I deal with this is I zero out the sources file, like ">
sources". Or another alternative that I use sometimes is "sha512sum
--tag", like:

   sha512sum --tag kstart-4.2.tar.gz > sources

- Ken
___
devel mailing list -- devel@lists.fedoraproject.org
To unsubscribe send an email to devel-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Do not reply to spam on the list, report it: 
https://pagure.io/fedora-infrastructure

___
devel mailing list -- devel@lists.fedoraproject.org
To unsubscribe send an email to devel-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Do not reply to spam on the list, report it: 
https://pagure.io/fedora-infrastructure


Re: Updating sources file using fedpkg

2021-06-17 Thread Otto Urpelainen

Ken Dreyer kirjoitti 17.6.2021 klo 19.04:

On Thu, Jun 17, 2021 at 8:33 AM Richard Shaw  wrote:


On Thu, Jun 17, 2021 at 7:22 AM Ewoud Kohl van Wijngaarden 
 wrote:



To be clear: I don't want to fiddle with the sources file, hence this
email. However, I would like to at least complete a local mockbuild
before uploading to the lookaside cache. It is my understanding that
new-sources always does this.



That's actually a nit I've been tempted to complain about. If I'm upgrading a 
package to a new version I update the spec file:

rpmdev-bumpspec -n  -c "Update to ." *.spec

And download the new source:

spectool -g *.spec

But then I have to upload the new source with 'fedpkg new-sources' if I don't 
want it to download the old version.


Yeah, the way I deal with this is I zero out the sources file, like ">
sources". Or another alternative that I use sometimes is "sha512sum
--tag", like:

   sha512sum --tag kstart-4.2.tar.gz > sources


Hi Ewould and everybody,

I am a bit confused about this discussion. My fedpkg does not care about 
the 'sources' file or the lookaside cache at all on 'fedpkg mockbuild'. 
It simply looks up the expected filename of downloaded Source, grabs it 
from the local working directory and uses that. So for me this works:


rpmdev-bumpspec -D -n 1.2.3 *.spec
# Update specfile as needed
spectool -g *.spec
fedpkg mockbuild

After that is done, the rpm is available at results_mypackage, I install 
it locally and see that everything works. At that point it is a good 
time do 'fedpkg new-sources'.


This also means that non-packagers actually *can* properly test their 
changes. The maintainer has to do new-sources, commit, push and build 
after merging the pull request, so annoyingly there are those steps to 
remember. But at least the pull request author does not have to submit 
their changes blindly.


A simple test to make sure that it really uses the local download:

$ sed -i 's/^Source.*/Source:https:\/\/example.com\/foo/' *.spec
$ fedpkg mockbuild
SOME_OUTPUT
error: Bad file: SOMEPATH/foo: No such file or directory
$ touch foo
$ fedpkg mockbuild
LOTS_OF_OUTPUT
SOME_ERROR_DUE_TO_EMPTY_SOURCE

When I started, I was having exactly the same trouble, so wrote 
something in the wiki:


https://fedoraproject.org/wiki/Package_maintenance_guide#Using_fedpkg_anonymously

Otto
___
devel mailing list -- devel@lists.fedoraproject.org
To unsubscribe send an email to devel-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Do not reply to spam on the list, report it: 
https://pagure.io/fedora-infrastructure


Re: Updating sources file using fedpkg

2021-06-17 Thread Ken Dreyer
On Thu, Jun 17, 2021 at 8:33 AM Richard Shaw  wrote:
>
> On Thu, Jun 17, 2021 at 7:22 AM Ewoud Kohl van Wijngaarden 
>  wrote:
>>
>>
>> To be clear: I don't want to fiddle with the sources file, hence this
>> email. However, I would like to at least complete a local mockbuild
>> before uploading to the lookaside cache. It is my understanding that
>> new-sources always does this.
>
>
> That's actually a nit I've been tempted to complain about. If I'm upgrading a 
> package to a new version I update the spec file:
>
> rpmdev-bumpspec -n  -c "Update to ." *.spec
>
> And download the new source:
>
> spectool -g *.spec
>
> But then I have to upload the new source with 'fedpkg new-sources' if I don't 
> want it to download the old version.

Yeah, the way I deal with this is I zero out the sources file, like ">
sources". Or another alternative that I use sometimes is "sha512sum
--tag", like:

  sha512sum --tag kstart-4.2.tar.gz > sources

- Ken
___
devel mailing list -- devel@lists.fedoraproject.org
To unsubscribe send an email to devel-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Do not reply to spam on the list, report it: 
https://pagure.io/fedora-infrastructure


Re: Updating sources file using fedpkg

2021-06-17 Thread Tom Hughes via devel

On 17/06/2021 12:57, Ewoud Kohl van Wijngaarden wrote:

After that, I'm looking for a command to update the sources file with 
new checksums so I can run:


fedpkg new-sources 

I could not find such a command so until now I've been using sha512sum 
manually, but there must be a better way :)


Well that will work for a local build but as it won't
upload them to the lookaside it won't work in koji.

Tom

--
Tom Hughes (t...@compton.nu)
http://compton.nu/
___
devel mailing list -- devel@lists.fedoraproject.org
To unsubscribe send an email to devel-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Do not reply to spam on the list, report it: 
https://pagure.io/fedora-infrastructure


Re: Updating sources file using fedpkg

2021-06-17 Thread Richard Shaw
On Thu, Jun 17, 2021 at 7:22 AM Ewoud Kohl van Wijngaarden <
ewoud+fed...@kohlvanwijngaarden.nl> wrote:

>
> To be clear: I don't want to fiddle with the sources file, hence this
> email. However, I would like to at least complete a local mockbuild
> before uploading to the lookaside cache. It is my understanding that
> new-sources always does this.
>

That's actually a nit I've been tempted to complain about. If I'm upgrading
a package to a new version I update the spec file:

rpmdev-bumpspec -n  -c "Update to ." *.spec

And download the new source:

spectool -g *.spec

But then I have to upload the new source with 'fedpkg new-sources' if I
don't want it to download the old version.

Perhaps fedpkg could check if the new source is available before
automatically downloading whatever is in the 'sources" file.

Thanks,
Richard
___
devel mailing list -- devel@lists.fedoraproject.org
To unsubscribe send an email to devel-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Do not reply to spam on the list, report it: 
https://pagure.io/fedora-infrastructure


Re: Updating sources file using fedpkg

2021-06-17 Thread Ewoud Kohl van Wijngaarden

On Thu, Jun 17, 2021 at 02:11:41PM +0200, Matthias Runge wrote:

On Thu, Jun 17, 2021 at 01:57:03PM +0200, Ewoud Kohl van Wijngaarden wrote:

Hello everyone,

As someone who just got started, I'm looking for some help.

I'd like to update packages. I'm used to git, so my typical flow is to make
sure I have some clean branch to start working from (clone is just for
completeness):

fedpkg clone mypackage
cd mypackage
git checkout -b rawhide-update-to-new-version
rpmdev-bumpspec -n 1.2.3 mypackage.spec

Now comes the part I'm not sure about. To fetch the new sources I usually
perform:

spectool -g mypackage.spec

After that, I'm looking for a command to update the sources file with new
checksums so I can run:


fedpkg new-sources

This should push the new sources (compressed tarball, whatever), defined
under SOURCE* in the spec file to the cache storing the sources.
For just local builds, this step is not necessary. You could run

fedpkg mockbuild


I found that mockbuild still retrieves what's in sources. I guess a 
possible workaround is to remove the entries from sources and rely on 
spectool.


As a non-packager you also can't run new-source. So perhaps new-sources 
should gain a --no-upload flag? --noop sounds wrong if it does make 
changes and a prep-sources command makes the command listing less 
useful.

___
devel mailing list -- devel@lists.fedoraproject.org
To unsubscribe send an email to devel-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Do not reply to spam on the list, report it: 
https://pagure.io/fedora-infrastructure


Re: Updating sources file using fedpkg

2021-06-17 Thread Ewoud Kohl van Wijngaarden

On Thu, Jun 17, 2021 at 02:05:16PM +0200, Fabio Valentini wrote:

On Thu, Jun 17, 2021 at 1:57 PM Ewoud Kohl van Wijngaarden
 wrote:


Hello everyone,

As someone who just got started, I'm looking for some help.

I'd like to update packages. I'm used to git, so my typical flow is to
make sure I have some clean branch to start working from (clone is just
for completeness):

fedpkg clone mypackage
cd mypackage
git checkout -b rawhide-update-to-new-version
rpmdev-bumpspec -n 1.2.3 mypackage.spec

Now comes the part I'm not sure about. To fetch the new sources I
usually perform:

spectool -g mypackage.spec

After that, I'm looking for a command to update the sources file with
new checksums so I can run:

fedpkg --release f35 mockbuild

I could not find such a command so until now I've been using sha512sum
manually, but there must be a better way :)


I assume you're looking for the "fedpkg new-sources" subcommand.

Using sha512sum alone is not doing everything you need, i.e. it's not
uploading the sources to the dist-git lookaside cache, so not using
"fedpkg new-sources" but only fiddling with the "sources" file
manually would result in broken builds, because the build system would
not find those sources.


To be clear: I don't want to fiddle with the sources file, hence this 
email. However, I would like to at least complete a local mockbuild 
before uploading to the lookaside cache. It is my understanding that 
new-sources always does this.



PS: I would recommend not creating custom branches, not even locally.
If you ever accidentally push such a branch, you might not be able to
delete it, *ever*. Additionally, if you stick to the normal "rawhide",
"f34", "f33" branches, then "fedpkg mockbuild" will infer the
"--release fXX" argument for you instead of you having to specify it
manually.


This feels very odd to me as a new contributor but very familiar with 
git.

___
devel mailing list -- devel@lists.fedoraproject.org
To unsubscribe send an email to devel-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Do not reply to spam on the list, report it: 
https://pagure.io/fedora-infrastructure


Re: Updating sources file using fedpkg

2021-06-17 Thread Matthias Runge
On Thu, Jun 17, 2021 at 01:57:03PM +0200, Ewoud Kohl van Wijngaarden wrote:
> Hello everyone,
> 
> As someone who just got started, I'm looking for some help.
> 
> I'd like to update packages. I'm used to git, so my typical flow is to make
> sure I have some clean branch to start working from (clone is just for
> completeness):
> 
> fedpkg clone mypackage
> cd mypackage
> git checkout -b rawhide-update-to-new-version
> rpmdev-bumpspec -n 1.2.3 mypackage.spec
> 
> Now comes the part I'm not sure about. To fetch the new sources I usually
> perform:
> 
> spectool -g mypackage.spec
> 
> After that, I'm looking for a command to update the sources file with new
> checksums so I can run:

fedpkg new-sources

This should push the new sources (compressed tarball, whatever), defined
under SOURCE* in the spec file to the cache storing the sources.
For just local builds, this step is not necessary. You could run

fedpkg mockbuild

Hope that helps,
Matthias
-- 
Matthias Runge 
___
devel mailing list -- devel@lists.fedoraproject.org
To unsubscribe send an email to devel-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Do not reply to spam on the list, report it: 
https://pagure.io/fedora-infrastructure


Re: Updating sources file using fedpkg

2021-06-17 Thread Fabio Valentini
On Thu, Jun 17, 2021 at 1:57 PM Ewoud Kohl van Wijngaarden
 wrote:
>
> Hello everyone,
>
> As someone who just got started, I'm looking for some help.
>
> I'd like to update packages. I'm used to git, so my typical flow is to
> make sure I have some clean branch to start working from (clone is just
> for completeness):
>
> fedpkg clone mypackage
> cd mypackage
> git checkout -b rawhide-update-to-new-version
> rpmdev-bumpspec -n 1.2.3 mypackage.spec
>
> Now comes the part I'm not sure about. To fetch the new sources I
> usually perform:
>
> spectool -g mypackage.spec
>
> After that, I'm looking for a command to update the sources file with
> new checksums so I can run:
>
> fedpkg --release f35 mockbuild
>
> I could not find such a command so until now I've been using sha512sum
> manually, but there must be a better way :)

I assume you're looking for the "fedpkg new-sources" subcommand.

Using sha512sum alone is not doing everything you need, i.e. it's not
uploading the sources to the dist-git lookaside cache, so not using
"fedpkg new-sources" but only fiddling with the "sources" file
manually would result in broken builds, because the build system would
not find those sources.

PS: I would recommend not creating custom branches, not even locally.
If you ever accidentally push such a branch, you might not be able to
delete it, *ever*. Additionally, if you stick to the normal "rawhide",
"f34", "f33" branches, then "fedpkg mockbuild" will infer the
"--release fXX" argument for you instead of you having to specify it
manually.

Fabio
___
devel mailing list -- devel@lists.fedoraproject.org
To unsubscribe send an email to devel-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Do not reply to spam on the list, report it: 
https://pagure.io/fedora-infrastructure