Menu

#859 Repository mapping lost when downloading team project

4.1
closed-fixed
None
1
2017-08-09
2017-04-27
No

A team project's omegat.project containing repository mappings is overwritten by OmegaT on project download, deleting all repository mappings, except for the default team project mapping, which is preserved (or created if it did not exist in the master file).

Example 1:

Master file and local copy in .repository/repository1 contain no default team project mapping and one (1) other repository mapping:

        <support_default_translations>true</support_default_translations>
        <remove_tags>false</remove_tags>
        <external_command></external_command>
        <repositories>
            <repository type="git" url="https://github.com/[my_project]/[repository2].git">
                <mapping local="tm" repository="">
                    <excludes>**/*</excludes>
                    <includes>**/[subfolder1]/**</includes>
                </mapping>
            </repository>
        </repositories>
    </project>

Local copy in project root contains the default team project mapping and no (0) other repository mapping:

        <support_default_translations>true</support_default_translations>
        <remove_tags>false</remove_tags>
        <external_command></external_command>
        <repositories>
            <repository type="git" url="https://github.com/[my_project]/[repository1].git">
                <mapping local="" repository=""/>
            </repository>
        </repositories>
    </project>

Example 2:

Master file and local copy in .repository/repository1 contain both the default team project mapping and one (1) other repository mapping:

        <support_default_translations>true</support_default_translations>
        <remove_tags>false</remove_tags>
        <external_command></external_command>
        <repositories>
            <repository type="git" url="https://github.com/[my_project]/[repository1].git">
                <mapping local="" repository=""/>
            </repository>
            <repository type="git" url="https://github.com/[my_project]/[repository2].git">
                <mapping local="tm" repository="">
                    <excludes>**/*</excludes>
                    <includes>**/[subfolder1]/**</includes>
                </mapping>
            </repository>
        </repositories>
    </project>

Local copy in project root contains the default team project mapping and no (0) other repository mapping:

        <support_default_translations>true</support_default_translations>
        <remove_tags>false</remove_tags>
        <external_command></external_command>
        <repositories>
            <repository type="git" url="https://github.com/[my_project]/[repository1].git">
                <mapping local="" repository=""/>
            </repository>
        </repositories>
    </project>

Key:

repository1 = team project repository (containing versioned project-save.tmx and glossary.txt)
repository2 = tm file repository

A workaround has been to copy omegat.project in Example 2 from .repositories/repository1 to the project's root, overwriting the omegat.project file created by OmegaT on project download and reloading the project. The same does not work for Example 1, as it turns the project into a non-team project.

Discussion

  • Didier Briel

    Didier Briel - 2017-07-26
    • summary: omegat.project in Team Project is overwritten on project download and any repository mappings are lost --> Repository mapping lost when downloading team project
    • assigned_to: Didier Briel
     
  • Didier Briel

    Didier Briel - 2017-07-26

    Fixed in SVN (/trunk, revision 10032).

    If there is no mapping at all in omegat.project, we assume it's a 3.6 project, and add the default mapping as described above.

    If there is any mapping, we do not change it (i.e., we do not attempt to add the default team project mapping).

    Didier

     
  • Didier Briel

    Didier Briel - 2017-08-09
    • status: open --> closed-fixed
     
  • Didier Briel

    Didier Briel - 2017-08-09

    Fixed in the released version 4.1.2 update 1 of OmegaT.

    Didier

     

Log in to post a comment.

MongoDB Logo MongoDB