Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.debian.user > #261569 > unrolled thread
| Started by | Tom Browder <tom.browder@gmail.com> |
|---|---|
| First post | 2023-09-10 01:40 +0200 |
| Last post | 2023-09-11 12:30 +0200 |
| Articles | 7 — 3 participants |
Back to article view | Back to linux.debian.user
xclip - how to use without a graphics display for testing on Github workflows Tom Browder <tom.browder@gmail.com> - 2023-09-10 01:40 +0200
Re: xclip - how to use without a graphics display for testing on Github workflows Greg Wooledge <greg@wooledge.org> - 2023-09-10 01:50 +0200
Re: xclip - how to use without a graphics display for testing on Github workflows Tom Browder <tom.browder@gmail.com> - 2023-09-10 02:50 +0200
Re: xclip - how to use without a graphics display for testing on Github workflows Max Nikulin <manikulin@gmail.com> - 2023-09-10 04:10 +0200
Re: xclip - how to use without a graphics display for testing on Github workflows Tom Browder <tom.browder@gmail.com> - 2023-09-10 11:50 +0200
Re: xclip - how to use without a graphics display for testing on Github workflows Max Nikulin <manikulin@gmail.com> - 2023-09-10 18:50 +0200
Re: xclip - how to use without a graphics display for testing on Github workflows Tom Browder <tom.browder@gmail.com> - 2023-09-11 12:30 +0200
| From | Tom Browder <tom.browder@gmail.com> |
|---|---|
| Date | 2023-09-10 01:40 +0200 |
| Subject | xclip - how to use without a graphics display for testing on Github workflows |
| Message-ID | <HcfIt-7TXS-7@gated-at.bofh.it> |
[Multipart message — attachments visible in raw view] — view raw
We have a Raku module that uses "xclip" during use on a computer with a monitor. We need to test it with Github workflows which does not have a graphics device. Is there any "xclip" option to allow for testing without a graphics devivce without throwing an error? Or any suggestion for a work around? Thanks. -Tom
[toc] | [next] | [standalone]
| From | Greg Wooledge <greg@wooledge.org> |
|---|---|
| Date | 2023-09-10 01:50 +0200 |
| Subject | Re: xclip - how to use without a graphics display for testing on Github workflows |
| Message-ID | <HcfS9-7U18-5@gated-at.bofh.it> |
| In reply to | #261569 |
On Sat, Sep 09, 2023 at 06:36:56PM -0500, Tom Browder wrote: > Is there any "xclip" option to allow for testing without a graphics devivce > without throwing an error? Or any suggestion for a work around? Look at the xvfb package. It gives an X server that exists entirely in memory, not needing a physical graphics chipset to run against. You can set DISPLAY to point to the xvfb server, and run X client programs in that environment.
[toc] | [prev] | [next] | [standalone]
| From | Tom Browder <tom.browder@gmail.com> |
|---|---|
| Date | 2023-09-10 02:50 +0200 |
| Subject | Re: xclip - how to use without a graphics display for testing on Github workflows |
| Message-ID | <HcgOd-7UyA-1@gated-at.bofh.it> |
| In reply to | #261570 |
[Multipart message — attachments visible in raw view] — view raw
On Sat, Sep 9, 2023 at 18:47 Greg Wooledge <greg@wooledge.org> wrote: > On Sat, Sep 09, 2023 at 06:36:56PM -0500, Tom Browder wrote: > > Is there any "xclip" option to allow for testing without a graphics > devivce … Thanks, Greg! -Tom
[toc] | [prev] | [next] | [standalone]
| From | Max Nikulin <manikulin@gmail.com> |
|---|---|
| Date | 2023-09-10 04:10 +0200 |
| Subject | Re: xclip - how to use without a graphics display for testing on Github workflows |
| Message-ID | <Hci3E-7VrC-3@gated-at.bofh.it> |
| In reply to | #261569 |
On 10/09/2023 06:36, Tom Browder wrote: > We have a Raku module that uses "xclip" during use on a computer with a > monitor. We need to test it with Github workflows which does not have a > graphics device. > > Is there any "xclip" option to allow for testing without a graphics > devivce without throwing an error? Or any suggestion for a work around? You can create a mock-up and use it instead of real xclip binary.
[toc] | [prev] | [next] | [standalone]
| From | Tom Browder <tom.browder@gmail.com> |
|---|---|
| Date | 2023-09-10 11:50 +0200 |
| Subject | Re: xclip - how to use without a graphics display for testing on Github workflows |
| Message-ID | <HcpeN-80fe-1@gated-at.bofh.it> |
| In reply to | #261573 |
[Multipart message — attachments visible in raw view] — view raw
On Sat, Sep 9, 2023 at 21:06 Max Nikulin <manikulin@gmail.com> wrote: > On 10/09/2023 06:36, Tom Browder wrote: > > We have a Raku module that uses "xclip" during use on a computer with a > > monitor. We need to test it with Github workflows which does not have a > > graphics device. > > > > Is there any "xclip" option to allow for testing without a graphics > > devivce without throwing an error? Or any suggestion for a work around? > > You can create a mock-up and use it instead of real xclip binary. Sounds interesting, Max, can you show the code? Thanks. Cheers! -Tom
[toc] | [prev] | [next] | [standalone]
| From | Max Nikulin <manikulin@gmail.com> |
|---|---|
| Date | 2023-09-10 18:50 +0200 |
| Subject | Re: xclip - how to use without a graphics display for testing on Github workflows |
| Message-ID | <HcvNf-84my-1@gated-at.bofh.it> |
| In reply to | #261575 |
On 10/09/2023 16:44, Tom Browder wrote:
> On Sat, Sep 9, 2023 at 21:06 Max Nikulin wrote:
>
>> You can create a mock-up and use it instead of real xclip binary.
>
> Sounds interesting, Max, can you show the code?
Unless you need to test subtle issues like
https://github.com/astrand/xclip/issues/20
"Not closing stdout when setting clipboard from stdin"
faced by e.g. tmux users, something simple should be enough:
#!/bin/sh -eu
: "${XCLIP_MOCK_FILE:=$HOME/.xclip-mock}"
while [ $# -gt 0 ]; do
case "$1" in
-i|-in)
;;
-o|--out) exec cat -- "$XCLIP_MOCK_FILE"
;;
-selection|-target) shift
;;
*) # FIXME xclip treats all unknown options at any position as files
break
;;
esac
shift
done
exec cat -- "$@" >"$XCLIP_MOCK_FILE"
[toc] | [prev] | [next] | [standalone]
| From | Tom Browder <tom.browder@gmail.com> |
|---|---|
| Date | 2023-09-11 12:30 +0200 |
| Subject | Re: xclip - how to use without a graphics display for testing on Github workflows |
| Message-ID | <HcMl4-8f2Y-3@gated-at.bofh.it> |
| In reply to | #261577 |
[Multipart message — attachments visible in raw view] — view raw
On Sun, Sep 10, 2023 at 11:49 Max Nikulin <manikulin@gmail.com> wrote:
> On 10/09/2023 16:44, Tom Browder wrote:
> > On Sat, Sep 9, 2023 at 21:06 Max Nikulin wrote:
> >
> >> You can create a mock-up and use it instead of real xclip binary.
> >
> > Sounds interesting, Max, can you show the code?
>
> Unless you need to test subtle issues like
>
> https://github.com/astrand/xclip/issues/20
> "Not closing stdout when setting clipboard from stdin"
>
> faced by e.g. tmux users, something simple should be enough:
>
> #!/bin/sh -eu
> : "${XCLIP_MOCK_FILE:=$HOME/.xclip-mock}"
>
> while [ $# -gt 0 ]; do
> case "$1" in
> -i|-in)
> ;;
> -o|--out) exec cat -- "$XCLIP_MOCK_FILE"
> ;;
> -selection|-target) shift
> ;;
> *) # FIXME xclip treats all unknown options at any
> position as files
> break
> ;;
> esac
> shift
> done
> exec cat -- "$@" >"$XCLIP_MOCK_FILE"
Thank, Max! I'll pass it on to the guy who needs it. He slings Wolfram
language code for a living.
Best regards,
-Tom
[toc] | [prev] | [standalone]
Back to top | Article view | linux.debian.user
csiph-web