Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
L
libcifpp
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
open
libcifpp
Commits
ce9842f6
Unverified
Commit
ce9842f6
authored
Nov 08, 2022
by
Maarten L. Hekkelman
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix in PDB export
Better add_git_submodule
parent
b784433f
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
31 additions
and
28 deletions
+31
-28
cmake/AddGitSubmodule.cmake
+1
-1
src/pdb/cif2pdb.cpp
+30
-27
No files found.
cmake/AddGitSubmodule.cmake
View file @
ce9842f6
...
@@ -10,7 +10,7 @@ function(add_git_submodule dir)
...
@@ -10,7 +10,7 @@ function(add_git_submodule dir)
# add_git_submodule(mysubmod_dir)
# add_git_submodule(mysubmod_dir)
find_package
(
Git QUIET
)
find_package
(
Git QUIET
)
if
(
NOT EXISTS
${
dir
}
/CMakeLists.txt
)
if
(
NOT EXISTS
"
${
PROJECT_SOURCE_DIR
}
/
${
dir
}
/CMakeLists.txt"
)
if
(
NOT
(
GIT_FOUND AND IS_DIRECTORY
"
${
CMAKE_CURRENT_SOURCE_DIR
}
/.git"
))
if
(
NOT
(
GIT_FOUND AND IS_DIRECTORY
"
${
CMAKE_CURRENT_SOURCE_DIR
}
/.git"
))
message
(
FATAL_ERROR
"
${
CMAKE_CURRENT_SOURCE_DIR
}
is not a git repository and the submodule
${
dir
}
is not complete. Cannot continue."
)
message
(
FATAL_ERROR
"
${
CMAKE_CURRENT_SOURCE_DIR
}
is not a git repository and the submodule
${
dir
}
is not complete. Cannot continue."
)
else
()
else
()
...
...
src/pdb/cif2pdb.cpp
View file @
ce9842f6
...
@@ -2458,36 +2458,39 @@ void WriteRemark350(std::ostream &pdbFile, const datablock &db)
...
@@ -2458,36 +2458,39 @@ void WriteRemark350(std::ostream &pdbFile, const datablock &db)
auto
gen
=
db
[
"pdbx_struct_assembly_gen"
].
find1
(
key
(
"assembly_id"
)
==
id
);
auto
gen
=
db
[
"pdbx_struct_assembly_gen"
].
find1
(
key
(
"assembly_id"
)
==
id
);
std
::
string
asym_id_list
,
oper_id_list
;
if
(
gen
)
cif
::
tie
(
asym_id_list
,
oper_id_list
)
=
gen
.
get
(
"asym_id_list"
,
"oper_expression"
);
{
std
::
string
asym_id_list
,
oper_id_list
;
cif
::
tie
(
asym_id_list
,
oper_id_list
)
=
gen
.
get
(
"asym_id_list"
,
"oper_expression"
);
auto
asyms
=
split
<
std
::
string
>
(
asym_id_list
,
","
);
auto
asyms
=
split
<
std
::
string
>
(
asym_id_list
,
","
);
std
::
vector
<
std
::
string
>
chains
=
MapAsymIDs2ChainIDs
(
asyms
,
db
);
std
::
vector
<
std
::
string
>
chains
=
MapAsymIDs2ChainIDs
(
asyms
,
db
);
pdbFile
<<
RM
(
"APPLY THE FOLLOWING TO CHAINS: "
)
<<
join
(
chains
,
", "
)
<<
std
::
endl
;
pdbFile
<<
RM
(
"APPLY THE FOLLOWING TO CHAINS: "
)
<<
join
(
chains
,
", "
)
<<
std
::
endl
;
for
(
auto
oper_id
:
split
<
std
::
string
>
(
oper_id_list
,
","
,
true
))
for
(
auto
oper_id
:
split
<
std
::
string
>
(
oper_id_list
,
","
,
true
))
{
{
auto
r
=
db
[
"pdbx_struct_oper_list"
].
find1
(
key
(
"id"
)
==
oper_id
);
auto
r
=
db
[
"pdbx_struct_oper_list"
].
find1
(
key
(
"id"
)
==
oper_id
);
pdbFile
<<
RM
(
" BIOMT1 "
,
-
3
)
<<
Fs
(
r
,
"id"
)
pdbFile
<<
RM
(
" BIOMT1 "
,
-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,
"id"
)
<<
SEP
(
" "
,
-
9
,
6
)
<<
Ff
(
r
,
"matrix[3][1]"
)
<<
SEP
(
" "
,
-
9
,
6
)
<<
Ff
(
r
,
"matrix[3][1]"
)
<<
SEP
(
" "
,
-
9
,
6
)
<<
Ff
(
r
,
"matrix[3][2]"
)
<<
SEP
(
" "
,
-
9
,
6
)
<<
Ff
(
r
,
"matrix[3][2]"
)
<<
SEP
(
" "
,
-
9
,
6
)
<<
Ff
(
r
,
"matrix[3][3]"
)
<<
SEP
(
" "
,
-
9
,
6
)
<<
Ff
(
r
,
"matrix[3][3]"
)
<<
SEP
(
" "
,
-
14
,
5
)
<<
Ff
(
r
,
"vector[3]"
)
<<
SEP
(
" "
,
-
14
,
5
)
<<
Ff
(
r
,
"vector[3]"
)
<<
std
::
endl
;
<<
std
::
endl
;
}
}
}
}
}
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment