bodleian / armenian-mss

Armenian TEI Catalogue
1 stars 0 forks source link

information hidden in attributes #8

Open holfordm opened 5 years ago

holfordm commented 5 years ago

@Archpoet pointed out today that some fields in the Armenian catalogue contain only attributes, and that this information doesn't display. The example given was this handNote https://github.com/bodleian/armenian-mss/blob/de252c577cef9a01644219b832643f9fb83a55e4/collections/MS_Arm_d_1.xml#L65

In this case the best solution might be for @andrew-morrison to write an XSLT script to extract the @script value and display it additionally inside the element. <handNote scope="major" script="Bolorgir">Bolorgir</handNote>.

Are there other cases in this catalogue of elements with meaningful attributes but no text content?

andrew-morrison commented 5 years ago

Dimensions too, but they're missing any actual figures.

I can write a script in the New Year to insert content. It can be just the same word as in the attribute, or more than that. For example, here's one of Mohammad Emami's in the Wadham collection, in the Fihrist catalogue:

https://github.com/fihristorg/fihrist-mss/blob/bf002356552d31793afe3d545a6e9369fc9393b5/collections/wadham%20college%20(university%20of%20oxford)/WadhMinasian_210.xml#L110

@Archpoet: Just tell me what text you want for each of the following:

Archpoet commented 5 years ago

Andrew, I will provide you with a brief description of each type of script within a couple of days, something like the example you shared with me. The main issue that we have discussed with @holfordm is however that I will need some general training in working with xml files and that we need a basic template for new entries.

andrew-morrison commented 5 years ago

I have run a script on the Armenian records. If you look a any manuscript pages now (e.g. MS. Arm. d. 5) you'll see under Hand(s) the script is now displayed (or "Unknown" in the five records which lack the information.)

That is because each TEI now contains something like the following:

<handDesc>
   <handNote scope="major" script="erkatagir">Written in <ref target="https://armenian.bodleian.ox.ac.uk/about#erkatagir">Erkat‘agir</ref> script</handNote>
</handDesc>

The ref element points to the about page on the web site, which is where I have put the long descriptions of each type of script that you send me. If there is anything about that page you want to change or add, let me know.

Does this look reasonable?

BTW, @holfordm is working on a template.

Archpoet commented 5 years ago

Thank you, Andrew. It works absolute fine and I think it is sufficient. The only thing that I am worried about is the files we have been working on (not many but still some). Should we download the files anew and start the work from scratch for those files, or will you be able to collate the two?

andrew-morrison commented 5 years ago

If you open GitHub Desktop, and select Pull from the Repository menu, it should download all my changes and merge them into your local copies of the files. If you have made minor edits in other parts of the records, not in or near the handNote element, it should be able to do so automatically. Otherwise, it will display a message about "conflicts", and you'll need to edit the affected records, because it will have put both versions of the handNote one after the one, and you'll need to pick one and delete the other (and extra lines it will have added to mark the two.) Then commit and select Push from the Repository menu to make your changes available to me (and let me know if you want them published to the web site.)

Archpoet commented 5 years ago

I did. This is the message I receive:

"error: Your local changes to the following files would be overwritten by merge: collections/MS_Arm_b_1.xml Please commit your changes or stash them before you merge. Aborting"

andrew-morrison commented 5 years ago

OK, that means you have changes, which do clash with mine, but haven't committed them yet. If you want to keep your changes, click the Commit to master button in the bottom-right. Then try Pull again (then it will probably display the message about conflicts. If you don't want to keep your changes, right-click on the files listed under Changes and select Discard Changes... Then try Pull again.

Archpoet commented 5 years ago

I have almost finished the one of the MS Arm b.1. Shall I complete it and then commit it, or is it fine to do it now?

andrew-morrison commented 5 years ago

You can commit now, merge in my change to handNote, then continue working on it some more (including adding more detail to the handNote, if you wish.)

In general, it is better to commit as often as possible. Committing only records the changes you've made in your local copy (creating a version you can revert back to if you change your mind about subsequent changes). Nobody else can see you your commits until you push. Pushing is what updates the records on the GitHub servers, making your changes available for everyone else, and allowing me to publish those changes to the web site (it is also good to push frequently, as that avoids conflicts, but not if that would mean making available something which you wouldn't want to see on the web site.)

I hope that makes sense.

Archpoet commented 5 years ago

It makes sense. The problem is my "Commit to Master" button cannot be clicked; it's not highlighted. I am working on MAC: is there anything I should do first?

andrew-morrison commented 5 years ago

I have GitHub Desktop on a Mac. Obviously, I cannot replicate the state of your local copy or know if you are using the same version of the software as me. But one or both of the following should enable to the commit button:

Archpoet commented 5 years ago

I realised I had to write a "Summary" to be able to Commit it. So, I pressed the Commit to master and now it's gone.

andrew-morrison commented 5 years ago

Now you have committed, have you tried selecting Pull from the Repository menu?

Archpoet commented 5 years ago

So, after committing the file, I pressed Pull from repository. I now looked at the same file in Oxygen and there is a word Erkat'agir but no value is attached to it. Should I restart Oxygen to see your changes? By the way, after committing to master I also pressed Push. I am not sure if it worked.

andrew-morrison commented 5 years ago

Oxygen should update automatically (or at least pop up a message saying it has changed on disk and asking if you want to reload it.)

Please send me your local copy of MS Arm b.1. Also click on History in GitHub Desktop, select the entry for your commit, and take a screenshot of what is displayed.

andrew-morrison commented 5 years ago

Also please go to the Help menu in GitHub Desktop, select Show Logs in Finder, and send me the log file that begins with today's date.

Archpoet commented 5 years ago

Done.

andrew-morrison commented 5 years ago

The copy of MS_Arm_b_1.xml you sent me is valid (press Cmd+Shift+V in Oxygen). The handNote is as I changed it yesterday:

<handNote scope="major" script="unknown">Unknown script</handNote>

The word "Erkat'agir" is present in notes in 25 out of 29 msItem elements (they're numbered 1 to 36 but there are gaps) so I assume it is the predominant script in this manuscript. If so, I'd suggest changing the handNote to:

<handNote scope="major" script="erkatagir">Written in <ref target="https://armenian.bodleian.ox.ac.uk/about#erkatagir">Erkat‘agir</ref> script</handNote>

Bolorgir is mentioned in two works, so you could change that to something like this:

<handNote scope="major" script="erkatagir">Mostly written in <ref target="https://armenian.bodleian.ox.ac.uk/about#erkatagir">Erkat‘agir</ref> script</handNote>
<handNote scope="minor" script="bolorgir">Some works written in <ref target="https://armenian.bodleian.ox.ac.uk/about#bolorgir">Bolorgir</ref> script</handNote>

Although you can word it however you like, or add more details. When published to the web site, they will display as two paragraphs underneath the "Head(s)" heading, like in MS. Arm. g. 2. However, you still need to push your commits before that can happen.

You said you had pushed, but I cannot see your changes (if you had, your commits would be listed here.) Possibly that might be explained by an error message in the GitHub Desktop log file you sent which indicates you are running it from a mounted disk image. That shouldn't matter, as your local copy of the armenian-mss repository is presumably elsewhere (wherever you chose when you cloned it) but there might be something GitHub Desktop needs to write to before it will push files to the central servers. Quit GitHub Desktop, find the .dmg (in your Downloads folder?), open it, and drag "GitHub Desktop.app" to Applications. Then run via Launchpad and try to push again.

Of the two commits you sent me screenshots of, only one ("Update MS_Arm_b_1.(16_1_2019)") contains your changes. The other is the automatic one that is the result of merging your changes and mine when you pulled. It contains all of my changes from yesterday, but they appear under your name. This is a confusing aspect of Git, resulting from its being designed by and for software developers, but if you ignore any commits that start with the words "Merge branch" you should be all right.

holfordm commented 5 years ago

The templates have not been merged into the 'master' branch yet, but you can still view there. There is one 'simple' template - https://github.com/bodleian/consolidated-tei-schema/blob/template/template.xml - and one template to be used for composite/multi-part manuscripts - https://github.com/bodleian/consolidated-tei-schema/blob/template/template-msPart.xml. Please let me know of any improvements you would find useful.

andrew-morrison commented 5 years ago

Also let me know if you need any help with committing and pushing your changes to GitHub. I still cannot see any changes since my own on January 15th, adding handNote text for every record.

Archpoet commented 5 years ago

Hi Andrew, I am in the middle of deadline frenzy so I haven't done anything since our last conversation. I will inform you when I do. Sorry.