Update theme and regenerate public

This commit is contained in:
2016-11-14 09:27:03 +02:00
parent 3669ce96d2
commit f0480fa373
32 changed files with 4103 additions and 1219 deletions

View File

@ -2,35 +2,33 @@
<html lang="en">
<head>
<meta charset="utf-8">
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
<!-- The above 3 meta tags *must* come first in the head; any other head content must come *after* these tags -->
<meta name="description" content="">
<meta name="author" content="Alan Orth">
<meta property="og:title" content="Posts" />
<meta property="og:description" content="" />
<meta property="og:type" content="website" />
<meta property="og:url" content="https://alanorth.github.io/cgspace-notes/post/" />
<meta property="og:updated_time" content="2016-11-01T09:21:00&#43;03:00"/>
<!-- OpenGraph Metadata: http://ogp.me/ -->
<meta property="og:title" content="Posts">
<meta property="og:description" content="">
<meta property="og:type" content="blog">
<meta itemprop="name" content="Posts">
<meta itemprop="description" content="">
<meta property="og:url" content="https://alanorth.github.io/cgspace-notes/post/">
<!-- Metadata for Twitter: https://dev.twitter.com/cards/markup -->
<meta property="twitter:card" content="summary">
<meta property="twitter:title" content="Posts">
<meta property="twitter:description" content="">
@ -49,8 +47,15 @@
<!-- combined, minified CSS -->
<link href="https://alanorth.github.io/cgspace-notes/css/style.css" rel="stylesheet">
<!-- RSS 2.0 feed -->
<link href="https://alanorth.github.io/cgspace-notes/index.xml" type="application/rss+xml" rel="alternate">
<link href="https://alanorth.github.io/cgspace-notes/post/index.xml" rel="alternate" type="application/rss+xml" title="CGSpace Notes" />
<link href="https://alanorth.github.io/cgspace-notes/post/index.xml" rel="feed" type="application/rss+xml" title="CGSpace Notes" />
</head>
<body>
@ -79,7 +84,9 @@
<article class="blog-post">
<article class="blog-post">
<header>
<h2 class="blog-post-title"><a href="https://alanorth.github.io/cgspace-notes/2016-11/">November, 2016</a></h2>
<p class="blog-post-meta"><time datetime="2016-11-01T09:21:00&#43;03:00">Tue Nov 01, 2016</time> by Alan Orth in
@ -93,7 +100,9 @@
</article>
<article class="blog-post">
<article class="blog-post">
<header>
<h2 class="blog-post-title"><a href="https://alanorth.github.io/cgspace-notes/2016-10/">October, 2016</a></h2>
<p class="blog-post-meta"><time datetime="2016-10-03T15:53:00&#43;03:00">Mon Oct 03, 2016</time> by Alan Orth in
@ -107,7 +116,9 @@
</article>
<article class="blog-post">
<article class="blog-post">
<header>
<h2 class="blog-post-title"><a href="https://alanorth.github.io/cgspace-notes/2016-09/">September, 2016</a></h2>
<p class="blog-post-meta"><time datetime="2016-09-01T15:53:00&#43;03:00">Thu Sep 01, 2016</time> by Alan Orth in
@ -133,7 +144,9 @@
</article>
<article class="blog-post">
<article class="blog-post">
<header>
<h2 class="blog-post-title"><a href="https://alanorth.github.io/cgspace-notes/2016-08/">August, 2016</a></h2>
<p class="blog-post-meta"><time datetime="2016-08-01T15:53:00&#43;03:00">Mon Aug 01, 2016</time> by Alan Orth in
@ -163,7 +176,9 @@ $ git rebase -i dspace-5.5
</article>
<article class="blog-post">
<article class="blog-post">
<header>
<h2 class="blog-post-title"><a href="https://alanorth.github.io/cgspace-notes/2016-07/">July, 2016</a></h2>
<p class="blog-post-meta"><time datetime="2016-07-01T10:53:00&#43;03:00">Fri Jul 01, 2016</time> by Alan Orth in
@ -196,7 +211,9 @@ dspacetest=# select text_value from metadatavalue where metadata_field_id=3 and
</article>
<article class="blog-post">
<article class="blog-post">
<header>
<h2 class="blog-post-title"><a href="https://alanorth.github.io/cgspace-notes/2016-06/">June, 2016</a></h2>
<p class="blog-post-meta"><time datetime="2016-06-01T10:53:00&#43;03:00">Wed Jun 01, 2016</time> by Alan Orth in
@ -221,7 +238,9 @@ dspacetest=# select text_value from metadatavalue where metadata_field_id=3 and
</article>
<article class="blog-post">
<article class="blog-post">
<header>
<h2 class="blog-post-title"><a href="https://alanorth.github.io/cgspace-notes/2016-05/">May, 2016</a></h2>
<p class="blog-post-meta"><time datetime="2016-05-01T23:06:00&#43;03:00">Sun May 01, 2016</time> by Alan Orth in
@ -247,7 +266,9 @@ dspacetest=# select text_value from metadatavalue where metadata_field_id=3 and
</article>
<article class="blog-post">
<article class="blog-post">
<header>
<h2 class="blog-post-title"><a href="https://alanorth.github.io/cgspace-notes/2016-04/">April, 2016</a></h2>
<p class="blog-post-meta"><time datetime="2016-04-04T11:06:00&#43;03:00">Mon Apr 04, 2016</time> by Alan Orth in
@ -271,7 +292,9 @@ dspacetest=# select text_value from metadatavalue where metadata_field_id=3 and
</article>
<article class="blog-post">
<article class="blog-post">
<header>
<h2 class="blog-post-title"><a href="https://alanorth.github.io/cgspace-notes/2016-03/">March, 2016</a></h2>
<p class="blog-post-meta"><time datetime="2016-03-02T16:50:00&#43;03:00">Wed Mar 02, 2016</time> by Alan Orth in
@ -293,7 +316,9 @@ dspacetest=# select text_value from metadatavalue where metadata_field_id=3 and
</article>
<article class="blog-post">
<article class="blog-post">
<header>
<h2 class="blog-post-title"><a href="https://alanorth.github.io/cgspace-notes/2016-02/">February, 2016</a></h2>
<p class="blog-post-meta"><time datetime="2016-02-05T13:18:00&#43;03:00">Fri Feb 05, 2016</time> by Alan Orth in
@ -323,6 +348,7 @@ dspacetest=# select text_value from metadatavalue where metadata_field_id=3 and
<nav class="blog-pagination">
@ -331,12 +357,12 @@ dspacetest=# select text_value from metadatavalue where metadata_field_id=3 and
<a class="btn btn-outline-primary" href="/post/page/2/" role="button">Next page</a>
</nav>
</div> <!-- /.blog-main -->
<aside class="col-sm-3 offset-sm-1 blog-sidebar">
<aside class="col-sm-3 offset-sm-1 blog-sidebar">
@ -374,7 +400,6 @@ dspacetest=# select text_value from metadatavalue where metadata_field_id=3 and
</aside>
</div> <!-- /.row -->
</div> <!-- /.container -->

View File

@ -213,7 +213,7 @@ dspace=# select count(text_value) from metadatavalue where resource_type_id=2 an
&lt;/code&gt;&lt;/pre&gt;
&lt;ul&gt;
&lt;li&gt;Generate a list of all these so I can fix them in batch:&lt;/li&gt;
&lt;li&gt;Generate a list of all these so I can maybe fix them in batch:&lt;/li&gt;
&lt;/ul&gt;
&lt;pre&gt;&lt;code&gt;dspace=# \copy (select distinct text_lang, count(*) from metadatavalue where resource_type_id=2 group by text_lang order by count desc) to /tmp/text-langs.csv with csv;
@ -227,6 +227,38 @@ COPY 14
&lt;pre&gt;&lt;code&gt;dspace=# update metadatavalue set text_lang=&#39;en_US&#39; where resource_type_id=2 and metadata_field_id=203 and text_value=&#39;SEEDS&#39;;
UPDATE 85
&lt;/code&gt;&lt;/pre&gt;
&lt;ul&gt;
&lt;li&gt;The &lt;code&gt;fix-metadata.py&lt;/code&gt; script I have is meant for specific metadata values, so if I want to update some &lt;code&gt;text_lang&lt;/code&gt; values I should just do it directly in the database&lt;/li&gt;
&lt;li&gt;For example, on a limited set:&lt;/li&gt;
&lt;/ul&gt;
&lt;pre&gt;&lt;code&gt;dspace=# update metadatavalue set text_lang=NULL where resource_type_id=2 and metadata_field_id=203 and text_value=&#39;LIVESTOCK&#39; and text_lang=&#39;&#39;;
UPDATE 420
&lt;/code&gt;&lt;/pre&gt;
&lt;ul&gt;
&lt;li&gt;And assuming I want to do it for all fields:&lt;/li&gt;
&lt;/ul&gt;
&lt;pre&gt;&lt;code&gt;dspacetest=# update metadatavalue set text_lang=NULL where resource_type_id=2 and text_lang=&#39;&#39;;
UPDATE 183726
&lt;/code&gt;&lt;/pre&gt;
&lt;ul&gt;
&lt;li&gt;After that restarted Tomcat and PostgreSQL (because I&amp;rsquo;m superstitious about caches) and now I see the following in REST API query:&lt;/li&gt;
&lt;/ul&gt;
&lt;pre&gt;&lt;code&gt;$ curl -s -H &amp;quot;accept: application/json&amp;quot; -H &amp;quot;Content-Type: application/json&amp;quot; -X POST &amp;quot;http://localhost:8080/rest/items/find-by-metadata-field&amp;quot; -d &#39;{&amp;quot;key&amp;quot;: &amp;quot;cg.subject.ilri&amp;quot;,&amp;quot;value&amp;quot;: &amp;quot;SEEDS&amp;quot;}&#39; | jq length
71
$ curl -s -H &amp;quot;accept: application/json&amp;quot; -H &amp;quot;Content-Type: application/json&amp;quot; -X POST &amp;quot;http://localhost:8080/rest/items/find-by-metadata-field&amp;quot; -d &#39;{&amp;quot;key&amp;quot;: &amp;quot;cg.subject.ilri&amp;quot;,&amp;quot;value&amp;quot;: &amp;quot;SEEDS&amp;quot;, &amp;quot;language&amp;quot;:&amp;quot;&amp;quot;}&#39; | jq length
0
$ curl -s -H &amp;quot;accept: application/json&amp;quot; -H &amp;quot;Content-Type: application/json&amp;quot; -X POST &amp;quot;http://localhost:8080/rest/items/find-by-metadata-field&amp;quot; -d &#39;{&amp;quot;key&amp;quot;: &amp;quot;cg.subject.ilri&amp;quot;,&amp;quot;value&amp;quot;: &amp;quot;SEEDS&amp;quot;, &amp;quot;language&amp;quot;:&amp;quot;en_US&amp;quot;}&#39; | jq length
&lt;/code&gt;&lt;/pre&gt;
&lt;ul&gt;
&lt;li&gt;Not sure what&amp;rsquo;s going on, but Discovery shows 83 values, and database shows 85, so I&amp;rsquo;m going to reindex Discovery just in case&lt;/li&gt;
&lt;/ul&gt;
</description>
</item>

View File

@ -2,35 +2,33 @@
<html lang="en">
<head>
<meta charset="utf-8">
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
<!-- The above 3 meta tags *must* come first in the head; any other head content must come *after* these tags -->
<meta name="description" content="">
<meta name="author" content="Alan Orth">
<meta property="og:title" content="Posts" />
<meta property="og:description" content="" />
<meta property="og:type" content="website" />
<meta property="og:url" content="https://alanorth.github.io/cgspace-notes/post/" />
<meta property="og:updated_time" content="2016-01-13T13:18:00&#43;03:00"/>
<!-- OpenGraph Metadata: http://ogp.me/ -->
<meta property="og:title" content="Posts">
<meta property="og:description" content="">
<meta property="og:type" content="blog">
<meta itemprop="name" content="Posts">
<meta itemprop="description" content="">
<meta property="og:url" content="https://alanorth.github.io/cgspace-notes/post/">
<!-- Metadata for Twitter: https://dev.twitter.com/cards/markup -->
<meta property="twitter:card" content="summary">
<meta property="twitter:title" content="Posts">
<meta property="twitter:description" content="">
@ -49,8 +47,15 @@
<!-- combined, minified CSS -->
<link href="https://alanorth.github.io/cgspace-notes/css/style.css" rel="stylesheet">
<!-- RSS 2.0 feed -->
<link href="https://alanorth.github.io/cgspace-notes/index.xml" type="application/rss+xml" rel="alternate">
<link href="https://alanorth.github.io/cgspace-notes/post/index.xml" rel="alternate" type="application/rss+xml" title="CGSpace Notes" />
<link href="https://alanorth.github.io/cgspace-notes/post/index.xml" rel="feed" type="application/rss+xml" title="CGSpace Notes" />
</head>
<body>
@ -79,7 +84,9 @@
<article class="blog-post">
<article class="blog-post">
<header>
<h2 class="blog-post-title"><a href="https://alanorth.github.io/cgspace-notes/2016-01/">January, 2016</a></h2>
<p class="blog-post-meta"><time datetime="2016-01-13T13:18:00&#43;03:00">Wed Jan 13, 2016</time> by Alan Orth in
@ -101,7 +108,9 @@
</article>
<article class="blog-post">
<article class="blog-post">
<header>
<h2 class="blog-post-title"><a href="https://alanorth.github.io/cgspace-notes/2015-12/">December, 2015</a></h2>
<p class="blog-post-meta"><time datetime="2015-12-02T13:18:00&#43;03:00">Wed Dec 02, 2015</time> by Alan Orth in
@ -128,7 +137,9 @@
</article>
<article class="blog-post">
<article class="blog-post">
<header>
<h2 class="blog-post-title"><a href="https://alanorth.github.io/cgspace-notes/2015-11/">November, 2015</a></h2>
<p class="blog-post-meta"><time datetime="2015-11-23T17:00:57&#43;03:00">Mon Nov 23, 2015</time> by Alan Orth in
@ -155,6 +166,7 @@
<nav class="blog-pagination">
@ -163,12 +175,12 @@
</nav>
</div> <!-- /.blog-main -->
<aside class="col-sm-3 offset-sm-1 blog-sidebar">
<aside class="col-sm-3 offset-sm-1 blog-sidebar">
@ -206,7 +218,6 @@
</aside>
</div> <!-- /.row -->
</div> <!-- /.container -->