[Github-comments] Re: [geany/geany] CI: Use MSYS2 for Windows build (PR #3315)

2023-01-15 Thread Enrico Tröger via Github-comments
Merged #3315 into master.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/geany/geany/pull/3315#event-8230023077
You are receiving this because you are subscribed to this thread.

Message ID: 

[Github-comments] Re: [geany/geany] CI: Use MSYS2 for Windows build (PR #3315)

2023-01-15 Thread Enrico Tröger via Github-comments
@eht16 pushed 1 commit.

e2066d4f5f9600b0d8acd0ebeaeddebc93d1f15a  Use Ubuntu 20.04 for Linux CI builds

-- 
View it on GitHub:
https://github.com/geany/geany/pull/3315/files/f146c2eb70715e94d1e31931cdebb08c86f81799..e2066d4f5f9600b0d8acd0ebeaeddebc93d1f15a
You are receiving this because you are subscribed to this thread.

Message ID: 


[Github-comments] Re: [geany/geany] CI: Use MSYS2 for Windows build (PR #3315)

2023-01-10 Thread Thomas Martitz via Github-comments
@kugel- approved this pull request.





-- 
Reply to this email directly or view it on GitHub:
https://github.com/geany/geany/pull/3315#pullrequestreview-1242372786
You are receiving this because you are subscribed to this thread.

Message ID: 

[Github-comments] Re: [geany/geany] CI: Use MSYS2 for Windows build (PR #3315)

2023-01-08 Thread Enrico Tröger via Github-comments
I just cleaned up the commit history and removed temporary test settings, so 
this can be merged.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/geany/geany/pull/3315#issuecomment-1374928919
You are receiving this because you are subscribed to this thread.

Message ID: 

[Github-comments] Re: [geany/geany] CI: Use MSYS2 for Windows build (PR #3315)

2023-01-08 Thread Enrico Tröger via Github-comments
@eht16 pushed 1 commit.

f146c2eb70715e94d1e31931cdebb08c86f81799  CI: Use MSYS2 for Windows build

-- 
View it on GitHub:
https://github.com/geany/geany/pull/3315/files/92d1a4b7267ca87c355ee9438fb190cab21eaf10..f146c2eb70715e94d1e31931cdebb08c86f81799
You are receiving this because you are subscribed to this thread.

Message ID: 


[Github-comments] Re: [geany/geany] CI: Use MSYS2 for Windows build (PR #3315)

2023-01-08 Thread Enrico Tröger via Github-comments
@eht16 pushed 1 commit.

6cb951f3510ffb6b4d84b7c5d78010cd8ffe1f8f  Remove test settings

-- 
View it on GitHub:
https://github.com/geany/geany/pull/3315/files/4bdd15c1aa86f916a8dc362c4d09af570c51b344..6cb951f3510ffb6b4d84b7c5d78010cd8ffe1f8f
You are receiving this because you are subscribed to this thread.

Message ID: 


[Github-comments] Re: [geany/geany] CI: Use MSYS2 for Windows build (PR #3315)

2022-12-11 Thread Enrico Tröger via Github-comments
@eht16 pushed 1 commit.

4bdd15c1aa86f916a8dc362c4d09af570c51b344  GH Actions: Replace deprecated 
"set-output" command

-- 
View it on GitHub:
https://github.com/geany/geany/pull/3315/files/30becfd0c152969510490f13e3b42778e74e8d4d..4bdd15c1aa86f916a8dc362c4d09af570c51b344
You are receiving this because you are subscribed to this thread.

Message ID: 


[Github-comments] Re: [geany/geany] CI: Use MSYS2 for Windows build (PR #3315)

2022-12-11 Thread Enrico Tröger via Github-comments
@eht16 pushed 1 commit.

30becfd0c152969510490f13e3b42778e74e8d4d  Remove CRLF text conversion

-- 
View it on GitHub:
https://github.com/geany/geany/pull/3315/files/4ed3402359d70b0d63afafd62e96945bc95ff6ab..30becfd0c152969510490f13e3b42778e74e8d4d
You are receiving this because you are subscribed to this thread.

Message ID: 


[Github-comments] Re: [geany/geany] CI: Use MSYS2 for Windows build (PR #3315)

2022-12-11 Thread Enrico Tröger via Github-comments
@eht16 commented on this pull request.



> + log "Signing Geany binary files"
+   for binary_file_pattern in ${GEANY_RELEASE_BINARY_PATTERNS[@]}; do
+   for binary_file in $(ls ${binary_file_pattern}); do
+   sign_file ${binary_file}
+   done
+   done
+}
+
+
+convert_text_files_to_crlf() {
+   log "Converting line endings to CRLF in text files"
+   for text_file_pattern in ${GEANY_RELEASE_TEXTFILE_PATTERNS[@]}; do
+   for text_file in $(ls ${text_file_pattern}); do
+   mime_type=$(file --brief --mime-type ${text_file})
+   case $mime_type in text/*)
+   unix2dos ${text_file}

Thanks for creating the issue and the investigation.
Nice that Notepad now can handle non-CRLF line endings. This was the main 
reason I convert the line endings.

So I just removed the code from the build script here and in the G-P 
counterpart.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/geany/geany/pull/3315#discussion_r1045225775
You are receiving this because you are subscribed to this thread.

Message ID: 

[Github-comments] Re: [geany/geany] CI: Use MSYS2 for Windows build (PR #3315)

2022-12-11 Thread Enrico Tröger via Github-comments
@eht16 pushed 1 commit.

4ed3402359d70b0d63afafd62e96945bc95ff6ab  Remove CRLF text conversion

-- 
View it on GitHub:
https://github.com/geany/geany/pull/3315/files/47d397e52155d4510452030de3d7a966b29a22dc..4ed3402359d70b0d63afafd62e96945bc95ff6ab
You are receiving this because you are subscribed to this thread.

Message ID: 


[Github-comments] Re: [geany/geany] CI: Use MSYS2 for Windows build (PR #3315)

2022-12-06 Thread Thomas Martitz via Github-comments
@kugel- commented on this pull request.



> + log "Signing Geany binary files"
+   for binary_file_pattern in ${GEANY_RELEASE_BINARY_PATTERNS[@]}; do
+   for binary_file in $(ls ${binary_file_pattern}); do
+   sign_file ${binary_file}
+   done
+   done
+}
+
+
+convert_text_files_to_crlf() {
+   log "Converting line endings to CRLF in text files"
+   for text_file_pattern in ${GEANY_RELEASE_TEXTFILE_PATTERNS[@]}; do
+   for text_file in $(ls ${text_file_pattern}); do
+   mime_type=$(file --brief --mime-type ${text_file})
+   case $mime_type in text/*)
+   unix2dos ${text_file}

I opened #3350 

I would like to see the conversion to be removed from this PR since I'm not 
even sure it's necessary at all. Don't recent Windows version deal fine with LF 
line endings. I don't know if notepad alone is an indication but see 
https://devblogs.microsoft.com/commandline/extended-eol-in-notepad/, this fix 
is included in Windows 10 and 11.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/geany/geany/pull/3315#discussion_r1041083868
You are receiving this because you are subscribed to this thread.

Message ID: 

[Github-comments] Re: [geany/geany] CI: Use MSYS2 for Windows build (PR #3315)

2022-12-04 Thread Enrico Tröger via Github-comments
@eht16 pushed 1 commit.

47d397e52155d4510452030de3d7a966b29a22dc  Change infrastructure builders branch

-- 
View it on GitHub:
https://github.com/geany/geany/pull/3315/files/ef2b6e5039e021b1b5d613eff90996f9c53da709..47d397e52155d4510452030de3d7a966b29a22dc
You are receiving this because you are subscribed to this thread.

Message ID: 


[Github-comments] Re: [geany/geany] CI: Use MSYS2 for Windows build (PR #3315)

2022-11-19 Thread Enrico Tröger
@eht16 commented on this pull request.



> + log "Signing Geany binary files"
+   for binary_file_pattern in ${GEANY_RELEASE_BINARY_PATTERNS[@]}; do
+   for binary_file in $(ls ${binary_file_pattern}); do
+   sign_file ${binary_file}
+   done
+   done
+}
+
+
+convert_text_files_to_crlf() {
+   log "Converting line endings to CRLF in text files"
+   for text_file_pattern in ${GEANY_RELEASE_TEXTFILE_PATTERNS[@]}; do
+   for text_file in $(ls ${text_file_pattern}); do
+   mime_type=$(file --brief --mime-type ${text_file})
+   case $mime_type in text/*)
+   unix2dos ${text_file}

> A tarball created on Linux will have wrong line endings on Windows. The 
> normal build system should take care of that instead of being restricted to 
> CI.

As said above, if you want to do this, please create an issue or even better a 
PR to make the changes to the build system(s). Then we can remove the line 
conversion here.
I won't do it because I still think it's not such a big deal and I won't spend 
the time effort it needs.

> And how do you create Win32 releases if not using CI (as you mentioned in 
> another comment)?

As described on https://wiki.geany.org/howtos/win32/msys2, especially using the 
[attached](https://wiki.geany.org/_media/howtos/win32/geany-release.py.txt) 
script which also does the line ending conversion to CRLF.
In short, using a clean GIT clone with the release tag. At least with my GIT 
config the relevant files all have LF line endings and therefore need to be 
converted.
Using a release tarball wouldn't help here because it is created on Linux and 
so also has LF line endings.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/geany/geany/pull/3315#discussion_r1027082555
You are receiving this because you are subscribed to this thread.

Message ID: 

[Github-comments] Re: [geany/geany] CI: Use MSYS2 for Windows build (PR #3315)

2022-11-14 Thread Thomas Martitz
@kugel- commented on this pull request.



> + log "Signing Geany binary files"
+   for binary_file_pattern in ${GEANY_RELEASE_BINARY_PATTERNS[@]}; do
+   for binary_file in $(ls ${binary_file_pattern}); do
+   sign_file ${binary_file}
+   done
+   done
+}
+
+
+convert_text_files_to_crlf() {
+   log "Converting line endings to CRLF in text files"
+   for text_file_pattern in ${GEANY_RELEASE_TEXTFILE_PATTERNS[@]}; do
+   for text_file in $(ls ${text_file_pattern}); do
+   mime_type=$(file --brief --mime-type ${text_file})
+   case $mime_type in text/*)
+   unix2dos ${text_file}

A tarball created on Linux will have wrong line endings on Windows. The normal 
build system should take care of that instead of being restricted to CI.

And how do you create Win32 releases if not using CI (as you mentioned in 
another comment)?

-- 
Reply to this email directly or view it on GitHub:
https://github.com/geany/geany/pull/3315#discussion_r1022440502
You are receiving this because you are subscribed to this thread.

Message ID: 

[Github-comments] Re: [geany/geany] CI: Use MSYS2 for Windows build (PR #3315)

2022-11-14 Thread Thomas Martitz
Nevermind, the G-P PR shows how to install additional build dependencies.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/geany/geany/pull/3315#issuecomment-1314908967
You are receiving this because you are subscribed to this thread.

Message ID: 

[Github-comments] Re: [geany/geany] CI: Use MSYS2 for Windows build (PR #3315)

2022-11-13 Thread Enrico Tröger
@eht16 commented on this pull request.



> + sed -i -E "s/^!define PRODUCT_VERSION_ID \"@VERSION@.0.0\"/!define 
> PRODUCT_VERSION_ID \"${MAJOR}.${MINOR}.${PATCH}.90\"/" 
> ${GEANY_BUILD_DIR}/geany.nsi.in
+}
+
+
+build_geany() {
+   cd ${GEANY_BUILD_DIR}
+   log "Running autogen.sh"
+   ./autogen.sh
+   log "Running configure"
+   ./configure ${CONFIGURE_OPTIONS}
+   log "Running make"
+   make
+   log "Running install-strip"
+   make install-strip
+
+   cd /

Removed, thanks for the pointer.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/geany/geany/pull/3315#discussion_r1020905051
You are receiving this because you are subscribed to this thread.

Message ID: 

[Github-comments] Re: [geany/geany] CI: Use MSYS2 for Windows build (PR #3315)

2022-11-13 Thread Enrico Tröger
> Can you add a stub with an (perhaps commented out) example on how to build 
> new dependencies for CI builds?

I don't get it :(. Where should I add the example and what do you mean by 
"build new dependencies"?



-- 
Reply to this email directly or view it on GitHub:
https://github.com/geany/geany/pull/3315#issuecomment-1312731386
You are receiving this because you are subscribed to this thread.

Message ID: 

[Github-comments] Re: [geany/geany] CI: Use MSYS2 for Windows build (PR #3315)

2022-11-13 Thread Enrico Tröger
@eht16 pushed 1 commit.

ef2b6e5039e021b1b5d613eff90996f9c53da709  Remove unnecessary directory changes

-- 
View it on GitHub:
https://github.com/geany/geany/pull/3315/files/94b6e948360cd7a6bcc1dbe2e52a12ec737fda5e..ef2b6e5039e021b1b5d613eff90996f9c53da709
You are receiving this because you are subscribed to this thread.

Message ID: 


[Github-comments] Re: [geany/geany] CI: Use MSYS2 for Windows build (PR #3315)

2022-11-13 Thread Enrico Tröger
@eht16 commented on this pull request.



> + -ts http://zeitstempel.dfn.de/ \
+   -h sha512 \
+   -in ${1} \
+   -out ${1}-signed
+   mv ${1}-signed ${1}
+   else
+   echo "Skip signing due to missing certificate"
+   fi
+}
+
+
+sign_geany_binaries() {
+   log "Signing Geany binary files"
+   for binary_file_pattern in ${GEANY_RELEASE_BINARY_PATTERNS[@]}; do
+   for binary_file in $(ls ${binary_file_pattern}); do
+   sign_file ${binary_file}

osslsigncode (and probably the original "signcode.exe" tool) are made for 
signing binary files, see 
https://github.com/mtrojnar/osslsigncode#what-can-it-do.

To get sure things haven't changed, I tried to sign an arbitary text file:
```
root@9214a3c76917:/build# osslsigncode sign -certs /certs/cert.pem -key 
/certs/key.pem -n "Test file" -i "https://www.geany.org/; -ts 
http://zeitstempel.dfn.de/ -h sha512 -in /etc/wgetrc -out wgetrc-s
Unrecognized file type: /etc/wgetrc
140619785353856:error:0D0680A8:asn1 encoding routines:asn1_check_tlen:wrong 
tag:../crypto/asn1/tasn_dec.c:1149:
140619785353856:error:0D07803A:asn1 encoding 
routines:asn1_item_embed_d2i:nested asn1 
error:../crypto/asn1/tasn_dec.c:309:Type=PKCS8_PRIV_KEY_INFO
140619785353856:error:0D0680A8:asn1 encoding routines:asn1_check_tlen:wrong 
tag:../crypto/asn1/tasn_dec.c:1149:
140619785353856:error:0D08303A:asn1 encoding 
routines:asn1_template_noexp_d2i:nested asn1 
error:../crypto/asn1/tasn_dec.c:572:
140619785353856:error:0D0680A8:asn1 encoding routines:asn1_check_tlen:wrong 
tag:../crypto/asn1/tasn_dec.c:1149:
140619785353856:error:0D07803A:asn1 encoding 
routines:asn1_item_embed_d2i:nested asn1 
error:../crypto/asn1/tasn_dec.c:309:Type=RSAPrivateKey
140619785353856:error:04093004:rsa routines:old_rsa_priv_decode:RSA 
lib:../crypto/rsa/rsa_ameth.c:142:
140619785353856:error:0D0680A8:asn1 encoding routines:asn1_check_tlen:wrong 
tag:../crypto/asn1/tasn_dec.c:1149:
140619785353856:error:0D07803A:asn1 encoding 
routines:asn1_item_embed_d2i:nested asn1 
error:../crypto/asn1/tasn_dec.c:309:Type=PKCS8_PRIV_KEY_INFO
Failed
```

Note, for the CI builds nothing is signed because no certificates are available 
to the build container. It wouldn't make sense to sign automatically built code 
since we have no control over the build system and its integrity, how should we 
tell the user that the generated binaries are really clean?
Additionally, we had to give the build system access to the private key of a 
certificate which would mean Github can access and in the worst case manipulate 
the certificate.
So, CI builds should never be trusted.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/geany/geany/pull/3315#discussion_r1020902509
You are receiving this because you are subscribed to this thread.

Message ID: 

[Github-comments] Re: [geany/geany] CI: Use MSYS2 for Windows build (PR #3315)

2022-11-13 Thread Enrico Tröger
@eht16 commented on this pull request.



> + log "Signing Geany binary files"
+   for binary_file_pattern in ${GEANY_RELEASE_BINARY_PATTERNS[@]}; do
+   for binary_file in $(ls ${binary_file_pattern}); do
+   sign_file ${binary_file}
+   done
+   done
+}
+
+
+convert_text_files_to_crlf() {
+   log "Converting line endings to CRLF in text files"
+   for text_file_pattern in ${GEANY_RELEASE_TEXTFILE_PATTERNS[@]}; do
+   for text_file in $(ls ${text_file_pattern}); do
+   mime_type=$(file --brief --mime-type ${text_file})
+   case $mime_type in text/*)
+   unix2dos ${text_file}

Could any of you open that issue?
I still don't get the problem you see, as outlined above, a GIT clone on 
Windows probably gives the correct line endings and so I'm not really able to 
create an issue for an issue I don't understand :).

Here we are talking about a native Linux clone with native LF line endings and 
those we need to convert. IMO this is special to the CI build and so needs to 
be done here.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/geany/geany/pull/3315#discussion_r1020899688
You are receiving this because you are subscribed to this thread.

Message ID: 

[Github-comments] Re: [geany/geany] CI: Use MSYS2 for Windows build (PR #3315)

2022-10-29 Thread elextr
@elextr commented on this pull request.



> + log "Signing Geany binary files"
+   for binary_file_pattern in ${GEANY_RELEASE_BINARY_PATTERNS[@]}; do
+   for binary_file in $(ls ${binary_file_pattern}); do
+   sign_file ${binary_file}
+   done
+   done
+}
+
+
+convert_text_files_to_crlf() {
+   log "Converting line endings to CRLF in text files"
+   for text_file_pattern in ${GEANY_RELEASE_TEXTFILE_PATTERNS[@]}; do
+   for text_file in $(ls ${text_file_pattern}); do
+   mime_type=$(file --brief --mime-type ${text_file})
+   case $mime_type in text/*)
+   unix2dos ${text_file}

> IMO: Let's open an issue regarding the line ending issue. 

Agreed, and I would have thought the tarball problem would exist already, can 
anyone test it?

-- 
Reply to this email directly or view it on GitHub:
https://github.com/geany/geany/pull/3315#discussion_r1008769652
You are receiving this because you are subscribed to this thread.

Message ID: 

[Github-comments] Re: [geany/geany] CI: Use MSYS2 for Windows build (PR #3315)

2022-10-29 Thread Thomas Martitz
Can you add a stub with an (perhaps commented out) example on how to build new 
dependencies for CI builds? I'm still afraid that it's too hard for a random 
guy's PR to add a dependency without breaking CI.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/geany/geany/pull/3315#issuecomment-1295948718
You are receiving this because you are subscribed to this thread.

Message ID: 

[Github-comments] Re: [geany/geany] CI: Use MSYS2 for Windows build (PR #3315)

2022-10-29 Thread Thomas Martitz
@kugel- commented on this pull request.



> + -ts http://zeitstempel.dfn.de/ \
+   -h sha512 \
+   -in ${1} \
+   -out ${1}-signed
+   mv ${1}-signed ${1}
+   else
+   echo "Skip signing due to missing certificate"
+   fi
+}
+
+
+sign_geany_binaries() {
+   log "Signing Geany binary files"
+   for binary_file_pattern in ${GEANY_RELEASE_BINARY_PATTERNS[@]}; do
+   for binary_file in $(ls ${binary_file_pattern}); do
+   sign_file ${binary_file}

Why not sign all files?

-- 
Reply to this email directly or view it on GitHub:
https://github.com/geany/geany/pull/3315#pullrequestreview-1161032231
You are receiving this because you are subscribed to this thread.

Message ID: 

[Github-comments] Re: [geany/geany] CI: Use MSYS2 for Windows build (PR #3315)

2022-10-29 Thread Thomas Martitz
@kugel- commented on this pull request.



> + sed -i -E "s/^!define PRODUCT_VERSION_ID \"@VERSION@.0.0\"/!define 
> PRODUCT_VERSION_ID \"${MAJOR}.${MINOR}.${PATCH}.90\"/" 
> ${GEANY_BUILD_DIR}/geany.nsi.in
+}
+
+
+build_geany() {
+   cd ${GEANY_BUILD_DIR}
+   log "Running autogen.sh"
+   ./autogen.sh
+   log "Running configure"
+   ./configure ${CONFIGURE_OPTIONS}
+   log "Running make"
+   make
+   log "Running install-strip"
+   make install-strip
+
+   cd /



-- 
Reply to this email directly or view it on GitHub:
https://github.com/geany/geany/pull/3315#pullrequestreview-1161032143
You are receiving this because you are subscribed to this thread.

Message ID: 

[Github-comments] Re: [geany/geany] CI: Use MSYS2 for Windows build (PR #3315)

2022-10-29 Thread Thomas Martitz
@kugel- commented on this pull request.



> + log "Signing Geany binary files"
+   for binary_file_pattern in ${GEANY_RELEASE_BINARY_PATTERNS[@]}; do
+   for binary_file in $(ls ${binary_file_pattern}); do
+   sign_file ${binary_file}
+   done
+   done
+}
+
+
+convert_text_files_to_crlf() {
+   log "Converting line endings to CRLF in text files"
+   for text_file_pattern in ${GEANY_RELEASE_TEXTFILE_PATTERNS[@]}; do
+   for text_file in $(ls ${text_file_pattern}); do
+   mime_type=$(file --brief --mime-type ${text_file})
+   case $mime_type in text/*)
+   unix2dos ${text_file}

Well the CI builds shouldn't have "more features" than normal builds from 
source - source code is king!! If a hard dependency in the normal build is not 
wanted then there could be an optional dependency that is _coincidentally_ met 
by the CI.

I wouldn't want manual git or tarball builds to regress compared to CI builds 
(e.g. on Windows 7). Stuff like this is hard to track down even for experienced 
contributors.

IMO: Let's open an issue regarding the line ending issue. Then we either deal 
with it in the normal build or just live with it as suggested by @elextr . I 
can help with meson if that's a problem.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/geany/geany/pull/3315#discussion_r1008746141
You are receiving this because you are subscribed to this thread.

Message ID: 

[Github-comments] Re: [geany/geany] CI: Use MSYS2 for Windows build (PR #3315)

2022-10-22 Thread elextr
@elextr commented on this pull request.



> + log "Signing Geany binary files"
+   for binary_file_pattern in ${GEANY_RELEASE_BINARY_PATTERNS[@]}; do
+   for binary_file in $(ls ${binary_file_pattern}); do
+   sign_file ${binary_file}
+   done
+   done
+}
+
+
+convert_text_files_to_crlf() {
+   log "Converting line endings to CRLF in text files"
+   for text_file_pattern in ${GEANY_RELEASE_TEXTFILE_PATTERNS[@]}; do
+   for text_file in $(ls ${text_file_pattern}); do
+   mime_type=$(file --brief --mime-type ${text_file})
+   case $mime_type in text/*)
+   unix2dos ${text_file}

> Windows' Notepad which is not able to handle different line endings.

Works on my windows 11 tablet[^1].  Google says it was fixed in 2018, so any  
_supported_ version of Windows should be ok ;-P

> Regarding Git's core.eol: I'm not what happens on a native Windows clone but 
> here we use the already cloned repository from the CI job and even if we 
> would clone it ourselves

Ok, so its necessary for the CI job, but I was really addressing @kugel- 
"Anyone who builds Geany from source on Windows should do this right?" but IIUC 
their checkout would do it for them with default git settings.  If tarballs are 
going to be buildable on windows I guess its needed there as well since the 
tarball files are LF endings unless we make a special Windows tarball ... or 
just say they are *x or modern Windows only.

> Changing the setting to crlf might have other side effects we do not want.

Yes, IIUC "Bad things" will happen if we merge anything back on Linux with that 
setting.

[^1]: No, its a _tablet_ so Geany is no use as I don't develop on it, sorry 
can't help with windows builds ;-P

-- 
Reply to this email directly or view it on GitHub:
https://github.com/geany/geany/pull/3315#discussion_r1002602492
You are receiving this because you are subscribed to this thread.

Message ID: 

[Github-comments] Re: [geany/geany] CI: Use MSYS2 for Windows build (PR #3315)

2022-10-22 Thread Enrico Tröger
@eht16 commented on this pull request.



> + log "Signing Geany binary files"
+   for binary_file_pattern in ${GEANY_RELEASE_BINARY_PATTERNS[@]}; do
+   for binary_file in $(ls ${binary_file_pattern}); do
+   sign_file ${binary_file}
+   done
+   done
+}
+
+
+convert_text_files_to_crlf() {
+   log "Converting line endings to CRLF in text files"
+   for text_file_pattern in ${GEANY_RELEASE_TEXTFILE_PATTERNS[@]}; do
+   for text_file in $(ls ${text_file_pattern}); do
+   mime_type=$(file --brief --mime-type ${text_file})
+   case $mime_type in text/*)
+   unix2dos ${text_file}

I don't expect from Geany's build system to know whether it need to convert 
text files to the target system's preferences.
IMO this is very Windows specific and basically only necessary to be able to 
read our text files with Windows' Notepad which is not able to handle different 
line endings.

In Geany, we would need to properly integrate it in Autotools and Meson and 
also depend on "unix2dos".

Regarding Git's `core.eol`: I'm not what happens on a native Windows clone but 
here we use the already cloned repository from the CI job and even if we would 
clone it ourselves, it would be LF as everything in this script is executed on 
Linux.

Changing the setting to `crlf` might have other side effects we do not want.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/geany/geany/pull/3315#discussion_r1002525301
You are receiving this because you are subscribed to this thread.

Message ID: 

[Github-comments] Re: [geany/geany] CI: Use MSYS2 for Windows build (PR #3315)

2022-10-21 Thread elextr
@elextr commented on this pull request.



> + log "Signing Geany binary files"
+   for binary_file_pattern in ${GEANY_RELEASE_BINARY_PATTERNS[@]}; do
+   for binary_file in $(ls ${binary_file_pattern}); do
+   sign_file ${binary_file}
+   done
+   done
+}
+
+
+convert_text_files_to_crlf() {
+   log "Converting line endings to CRLF in text files"
+   for text_file_pattern in ${GEANY_RELEASE_TEXTFILE_PATTERNS[@]}; do
+   for text_file in $(ls ${text_file_pattern}); do
+   mime_type=$(file --brief --mime-type ${text_file})
+   case $mime_type in text/*)
+   unix2dos ${text_file}

Git should convert line endings on checkout since the default value of 
`core.eol` is `native` but maybe MSYS2 doesn't register "native" as CRLF?  
Maybe the scripts in MSYS2 should do `git config core.eol crlf`?

-- 
Reply to this email directly or view it on GitHub:
https://github.com/geany/geany/pull/3315#discussion_r1002255851
You are receiving this because you are subscribed to this thread.

Message ID: 

[Github-comments] Re: [geany/geany] CI: Use MSYS2 for Windows build (PR #3315)

2022-10-21 Thread Thomas Martitz
@kugel- commented on this pull request.



> + log "Signing Geany binary files"
+   for binary_file_pattern in ${GEANY_RELEASE_BINARY_PATTERNS[@]}; do
+   for binary_file in $(ls ${binary_file_pattern}); do
+   sign_file ${binary_file}
+   done
+   done
+}
+
+
+convert_text_files_to_crlf() {
+   log "Converting line endings to CRLF in text files"
+   for text_file_pattern in ${GEANY_RELEASE_TEXTFILE_PATTERNS[@]}; do
+   for text_file in $(ls ${text_file_pattern}); do
+   mime_type=$(file --brief --mime-type ${text_file})
+   case $mime_type in text/*)
+   unix2dos ${text_file}

Isn't that something that should be done in geany build itself? Anyone who 
builds Geany from source on Windows should do this right?

-- 
Reply to this email directly or view it on GitHub:
https://github.com/geany/geany/pull/3315#pullrequestreview-1151587323
You are receiving this because you are subscribed to this thread.

Message ID: 

[Github-comments] Re: [geany/geany] CI: Use MSYS2 for Windows build (PR #3315)

2022-10-16 Thread Enrico Tröger
@eht16 pushed 1 commit.

94b6e948360cd7a6bcc1dbe2e52a12ec737fda5e  Update actions to latest version for 
Node 16 update

-- 
View it on GitHub:
https://github.com/geany/geany/pull/3315/files/2a4f14667aa47bc5e78a34a0c09cfc05d82635e1..94b6e948360cd7a6bcc1dbe2e52a12ec737fda5e
You are receiving this because you are subscribed to this thread.

Message ID: 


[Github-comments] Re: [geany/geany] CI: Use MSYS2 for Windows build (PR #3315)

2022-10-16 Thread Enrico Tröger
@eht16 pushed 1 commit.

2a4f14667aa47bc5e78a34a0c09cfc05d82635e1  CI: Use MSYS2 for Windows build

-- 
View it on GitHub:
https://github.com/geany/geany/pull/3315/files/8e961c9d70ea119875ab21c450053148ea73557b..2a4f14667aa47bc5e78a34a0c09cfc05d82635e1
You are receiving this because you are subscribed to this thread.

Message ID: