Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add fc-virus recipe #51809

Merged
merged 105 commits into from
Nov 5, 2024
Merged
Show file tree
Hide file tree
Changes from 93 commits
Commits
Show all changes
105 commits
Select commit Hold shift + click to select a range
db3ebff
Create meta.yaml
qdu-bioinfo Oct 30, 2024
c20772a
Update meta.yaml
qdu-bioinfo Oct 30, 2024
ad5d462
Update meta.yaml
qdu-bioinfo Oct 30, 2024
d9334e8
Create LICENSE
qdu-bioinfo Oct 30, 2024
866bd6d
Create build.sh
qdu-bioinfo Oct 30, 2024
7d96345
Update meta.yaml
qdu-bioinfo Oct 30, 2024
3b56d0a
Update meta.yaml
qdu-bioinfo Oct 30, 2024
f67d05d
Update build.sh
qdu-bioinfo Oct 31, 2024
61ec829
Update build.sh
qdu-bioinfo Oct 31, 2024
b352495
Update meta.yaml
qdu-bioinfo Oct 31, 2024
5d49397
Update build.sh
qdu-bioinfo Oct 31, 2024
0d75e3c
Update meta.yaml
qdu-bioinfo Oct 31, 2024
06eaf2c
Update meta.yaml
qdu-bioinfo Oct 31, 2024
8d16ee8
Update meta.yaml
qdu-bioinfo Oct 31, 2024
03bdc68
Update build.sh
qdu-bioinfo Oct 31, 2024
f59f4d6
Update build.sh
qdu-bioinfo Oct 31, 2024
4f22236
Update build.sh
qdu-bioinfo Oct 31, 2024
f0221ce
Update build.sh
qdu-bioinfo Oct 31, 2024
0702de8
Update build.sh
qdu-bioinfo Oct 31, 2024
6bfc2de
Update build.sh
qdu-bioinfo Oct 31, 2024
5a3ae05
Update build.sh
qdu-bioinfo Oct 31, 2024
4988cb6
Update build.sh
qdu-bioinfo Oct 31, 2024
1f36454
Update build.sh
qdu-bioinfo Oct 31, 2024
ba5d11c
Update build.sh
qdu-bioinfo Oct 31, 2024
a1fbb60
Update build.sh
qdu-bioinfo Oct 31, 2024
77591fd
Update meta.yaml
qdu-bioinfo Oct 31, 2024
42458eb
Update build.sh
qdu-bioinfo Oct 31, 2024
c2a00b2
Delete recipes/fc/build.sh
qdu-bioinfo Oct 31, 2024
a6d9c66
Update meta.yaml
qdu-bioinfo Oct 31, 2024
ae33bdf
Update meta.yaml
qdu-bioinfo Oct 31, 2024
a22c1af
Update meta.yaml
qdu-bioinfo Oct 31, 2024
e3b9980
Update meta.yaml
qdu-bioinfo Oct 31, 2024
ca92f27
Update meta.yaml
qdu-bioinfo Oct 31, 2024
0120428
Update meta.yaml
qdu-bioinfo Oct 31, 2024
b3e9d8c
Update meta.yaml
qdu-bioinfo Oct 31, 2024
ea1e01b
Update meta.yaml
qdu-bioinfo Oct 31, 2024
31e40f2
Update meta.yaml
qdu-bioinfo Oct 31, 2024
358b44b
Update meta.yaml
qdu-bioinfo Oct 31, 2024
c909cf3
Update meta.yaml
qdu-bioinfo Oct 31, 2024
a1989ad
Update meta.yaml
qdu-bioinfo Oct 31, 2024
6ff3724
Update meta.yaml
qdu-bioinfo Oct 31, 2024
3a5eb28
Create build.sh
qdu-bioinfo Oct 31, 2024
59b2cdb
Update meta.yaml
qdu-bioinfo Oct 31, 2024
ed5e09d
Update build.sh
qdu-bioinfo Oct 31, 2024
91a74db
Update meta.yaml
qdu-bioinfo Oct 31, 2024
a318fd1
Update build.sh
qdu-bioinfo Oct 31, 2024
db2059a
Update meta.yaml
qdu-bioinfo Oct 31, 2024
ba636e5
Update build.sh
qdu-bioinfo Nov 1, 2024
b11df75
Update build.sh
qdu-bioinfo Nov 1, 2024
f92b076
Update build.sh
qdu-bioinfo Nov 1, 2024
1f4eaa3
Update build.sh
qdu-bioinfo Nov 1, 2024
a60ea99
Update build.sh
qdu-bioinfo Nov 1, 2024
04eb82e
Update build.sh
qdu-bioinfo Nov 1, 2024
8d18bfd
Update meta.yaml
qdu-bioinfo Nov 1, 2024
ff8e46a
Update build.sh
qdu-bioinfo Nov 1, 2024
91d9f88
Update meta.yaml
qdu-bioinfo Nov 1, 2024
65ce000
Update build.sh
qdu-bioinfo Nov 1, 2024
f7f92a5
Update meta.yaml
qdu-bioinfo Nov 1, 2024
a38e6f8
Update meta.yaml
qdu-bioinfo Nov 1, 2024
b661b76
Update meta.yaml
qdu-bioinfo Nov 2, 2024
84eb3fb
Update meta.yaml
qdu-bioinfo Nov 2, 2024
00c72f9
Update meta.yaml
qdu-bioinfo Nov 2, 2024
a9daef5
Update meta.yaml
qdu-bioinfo Nov 2, 2024
59d3665
Update meta.yaml
qdu-bioinfo Nov 2, 2024
2e8cc38
Update meta.yaml
qdu-bioinfo Nov 2, 2024
2fcf51b
Update meta.yaml
qdu-bioinfo Nov 2, 2024
a275ac6
Update build.sh
qdu-bioinfo Nov 2, 2024
b522818
Update build.sh
qdu-bioinfo Nov 2, 2024
b9e02ce
Update build.sh
qdu-bioinfo Nov 2, 2024
d9213cb
Update meta.yaml
qdu-bioinfo Nov 2, 2024
a4350ac
Update build.sh
qdu-bioinfo Nov 2, 2024
46dd88d
Update meta.yaml
qdu-bioinfo Nov 2, 2024
8a6c033
Update meta.yaml
qdu-bioinfo Nov 2, 2024
21de2d8
Update build.sh
qdu-bioinfo Nov 2, 2024
232bc3b
Update build.sh
qdu-bioinfo Nov 2, 2024
aee3e16
Update meta.yaml
qdu-bioinfo Nov 2, 2024
7939059
Update meta.yaml
qdu-bioinfo Nov 2, 2024
21985ed
Update meta.yaml
qdu-bioinfo Nov 2, 2024
cc7293d
Update meta.yaml
qdu-bioinfo Nov 2, 2024
0ee8123
Update build.sh
qdu-bioinfo Nov 2, 2024
9dbc37e
Update meta.yaml
qdu-bioinfo Nov 2, 2024
ec35aad
Update build.sh
qdu-bioinfo Nov 2, 2024
682295a
Update build.sh
qdu-bioinfo Nov 2, 2024
fee1416
Update meta.yaml
qdu-bioinfo Nov 2, 2024
18bd208
Update meta.yaml
qdu-bioinfo Nov 2, 2024
3554a1e
Update build.sh
qdu-bioinfo Nov 3, 2024
46747b9
Update meta.yaml
qdu-bioinfo Nov 3, 2024
017db5e
Update meta.yaml
qdu-bioinfo Nov 3, 2024
36ddabb
Update build.sh
qdu-bioinfo Nov 4, 2024
c3d253a
Update meta.yaml
qdu-bioinfo Nov 4, 2024
98be845
Update recipes/fc/meta.yaml
qdu-bioinfo Nov 4, 2024
2e649ba
Merge branch 'master' into patch-8
qdu-bioinfo Nov 4, 2024
4ac072e
Update meta.yaml
qdu-bioinfo Nov 4, 2024
39cc7cc
Update meta.yaml
qdu-bioinfo Nov 4, 2024
e56f76e
Update build.sh
mencian Nov 4, 2024
7591000
Update meta.yaml
mencian Nov 4, 2024
ed5726a
try fc
mencian Nov 4, 2024
4fe08da
edit source URL
mencian Nov 4, 2024
92e300d
Update build.sh
qdu-bioinfo Nov 5, 2024
e76937f
Update meta.yaml
qdu-bioinfo Nov 5, 2024
b27aaea
Update meta.yaml
qdu-bioinfo Nov 5, 2024
8751de1
Update meta.yaml
qdu-bioinfo Nov 5, 2024
fc41516
Update meta.yaml
mencian Nov 5, 2024
728593e
Update meta.yaml
mencian Nov 5, 2024
f2d34b3
Delete recipes/fc/LICENSE
mencian Nov 5, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 21 additions & 0 deletions recipes/fc/LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
MIT License

Copyright (c) [2022] [Runpeng Luo]

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
8 changes: 8 additions & 0 deletions recipes/fc/build.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@

#!/bin/bash
set -xe
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue

Fix shebang line position

The shebang must be on the first line of the script. Remove the blank line 1.

-
#!/bin/bash
+#!/bin/bash

set -xe
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
#!/bin/bash
set -xe
#!/bin/bash
set -xe
🧰 Tools
🪛 Shellcheck

[error] 2-2: The shebang must be on the first line. Delete blanks and move comments.

(SC1128)

make CXX="${CXX}" INCLUDES="-I$PREFIX/include" CFLAGS+="-g -Wall -O2 -L$PREFIX/lib"
#chmod +x ./bin/fc-virus
chmod 777 ./bin/fc-virus
Comment on lines +4 to +5
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue

Security: Fix overly permissive file permissions

Using chmod 777 grants read/write/execute permissions to all users, which is a security risk. The executable only needs to be executable by users (755).

-#chmod +x ./bin/fc-virus
-chmod 777 ./bin/fc-virus
+chmod 755 ./bin/fc-virus
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
#chmod +x ./bin/fc-virus
chmod 777 ./bin/fc-virus
chmod 755 ./bin/fc-virus

mkdir -p ${PREFIX}/bin
cp -f ./bin/fc-virus ${PREFIX}/bin
Comment on lines +6 to +7
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🛠️ Refactor suggestion

Add error handling for installation steps

The installation commands should:

  1. Validate that the binary exists before copying
  2. Use install command instead of cp for proper permission handling
  3. Add error handling for mkdir and copy operations
-mkdir -p ${PREFIX}/bin
-cp -f ./bin/fc-virus ${PREFIX}/bin
+if [ ! -f ./bin/fc-virus ]; then
+    echo "Error: fc-virus binary not found" >&2
+    exit 1
+fi
+mkdir -p "${PREFIX}/bin" || exit 1
+install -v -m 755 ./bin/fc-virus "${PREFIX}/bin/" || exit 1
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
mkdir -p ${PREFIX}/bin
cp -f ./bin/fc-virus ${PREFIX}/bin
if [ ! -f ./bin/fc-virus ]; then
echo "Error: fc-virus binary not found" >&2
exit 1
fi
mkdir -p "${PREFIX}/bin" || exit 1
install -v -m 755 ./bin/fc-virus "${PREFIX}/bin/" || exit 1

39 changes: 39 additions & 0 deletions recipes/fc/meta.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
{% set name = "fc-virus" %}
{% set version = "1.0.1" %}

package:
name: "fc"
version: {{ version }}


source:
url: "https://github.com/qdu-bioinfo/{{ name }}/archive/refs/tags/v{{ version }}.tar.gz"
sha256: "6545124184e7ac743ff8149e97a0972230dad4f458248d2cad088e329e91b836"
build:
number: 0
skip: true
run_exports:
- {{ pin_subpackage("fc", max_pin="x") }}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue

Remove redundant skip directive

The skip: true on line 14 would prevent building for all platforms, which conflicts with the platform-specific skip at the end of the file. Remove this line and keep only the platform-specific skip.

 build:
   number: 0
-  skip: true
   run_exports:
     - {{ pin_subpackage("fc", max_pin="x") }}
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
build:
number: 0
skip: true
run_exports:
- {{ pin_subpackage("fc", max_pin="x") }}
build:
number: 0
run_exports:
- {{ pin_subpackage("fc", max_pin="x") }}


requirements:
build:
- make
- {{ compiler('c') }}
host:
- zlib
- boost
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue

Add C++ compiler requirement

Since the package depends on boost, which is a C++ library, you should add the C++ compiler to the build requirements.

   build:
     - make
     - {{ compiler('c') }}
+    - {{ compiler('cxx') }}
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
requirements:
build:
- make
- {{ compiler('c') }}
host:
- zlib
- boost
requirements:
build:
- make
- {{ compiler('c') }}
- {{ compiler('cxx') }}
host:
- zlib
- boost



test:
commands:
- ./bin/fc-virus --help
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue

Fix test command path.

The current test command uses a relative path ./bin/fc-virus which may not work as expected. The binary should be in $PREFIX/bin after installation.

Apply this fix:

 test:
   commands:
-    - ./bin/fc-virus --help
+    - fc-virus --help
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
test:
commands:
- ./bin/fc-virus --help
test:
commands:
- fc-virus --help


about:
home: "https://github.com/qdu-bioinfo/fc-virus"
license: MIT
license_family: MIT
license_file: LICENSE
summary: "Accurate Assembly of Full-length Consensus for Viral Quasispecies"

skip:
- osx-64
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue

Move skip configuration to build section

The skip configuration should be under the build section, not at the root level.

 build:
   number: 0
   run_exports:
     - {{ pin_subpackage("fc", max_pin="x") }}
+  skip:
+    - osx-64

-skip:
-  - osx-64
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
skip:
- osx-64
build:
number: 0
run_exports:
- {{ pin_subpackage("fc", max_pin="x") }}
skip:
- osx-64

Loading