Tuesday, August 20, 2024

Reformatting footnotes in Libreoffice

 LibreOffice is amazing and I love it and its model of support and free distribution.  

Mostly, functionality is superb.  But as far as I can see, you can't globally select the text of footnotes.  That's weird.

However, it can be done with the help of an extension.  

  1. Download the AltSearch extension by Tomáš Bílek.  It's old, but as of August 2024 it works fine.
  2. Install it by double-clicking the download.  LibreOffice will open a menu for you and after installation you'll have to restart LibreOffice.
  3. With your document loaded, select the new green binoculars icon to open the AltSearch menu.
  4. Select "Properties/Paragraph style/Footnotes" and double click.
  5. Select "Find All" and "yes" to the "do you really want to" popup.
  6. Now all your footnote paragraphs are highlighted.   You can close the AltSearch window and use your normal formatting commands to reformat your footnotes.

Many thanks to manj_k who wrote the post that I am totally copying here.

Friday, August 02, 2024

TeXstudio under Ubuntu and equivs

Environment: Linux Mint and Ubuntu; separate TeXlive installation

The author of TeXstudio used to distribute deb files for each Linux distribution.  Understandably, that is laborious.  So now, only the PPA is given.  But if you add the PPA to your Linux "software sources" list and try to install TeXstudio, it had dependency links to the whole TeXlive system in the synaptic package library and tries to install all that too.  

The way round this is to create a dummy "TeXlive" installation without these dependencies using the "equivs" system.  (see here and here).

Steps:

  1. sudo apt-get install equivs
  2. Create a control file with this content:
    Section: tex
    Package: texlive-dummy
    Provides: tex-common, texlive-common, texlive-latex-base, texlive-metapost, texlive-xetex, texlive-base-bin, texlive-base-bin-doc, tex-common, tex-gyre, texlive-base, texlive-binaries, texlive-fonts-recommended, texlive-latex-base, texlive-latex-extra, texlive-latex-recommended, texlive-pictures
    Description: texlive dummy package This package provides dpkg with the information that there the texlive packages are already installed.
  3. Run the following:
    equivs-build texlive.ctl
    That produces the file texlive-dummy_1.0_all.deb  This is asudo dpkg -i texlive-dummy_1.0_all.deb "pretend" TeXlive (texlive-latex-base) package that contains no dependencies.
  4. Run
    sudo dpkg -i texlive-dummy_1.0_all.deb
    Now, your system believes it has installed texlive-latex-base, so dependencies on that will be satisfied.
  5. You can now install the TeXstudio PPA and install the TeXstudio program in the normal way.

Wednesday, May 29, 2024

Making your own Saktumiva server using Ubuntu

The following are instructions for using the command-line interface to set up your own instance of Charles Li’s Saktumiva (Upama) on your own Ubuntu-type server.* You’re going to be working in /var/www a lot, so you need to use sudo for almost all commands. Unless otherwise stated, you’ll do all these commands in the /var/www directory. I’m assuming that you sit in /var/www and to download files to that location, etc., using sudo all the time. (or just becoming root for a while sudo su).
  1. Install apache2 (not nginx; it probably works, but we’re doing apache2 here). 

     sudo apt-get install apache2  

    You will then have a directory /var/www/html which is where all your later files for Dokuwiki and Upama will go. Next, create a file  

    /etc/apache2/sites-available/dokuwiki.conf  

    with the contents

    <VirtualHost *:80>
      ServerAdmin <a href="/cdn-cgi/l/email-protection" class="__cf_email__" data-cfemail="b1d0d5dcd8dff1d4c9d0dcc1ddd49fd2dedc">[email protected]</a>
      DocumentRoot /var/www/html/
      ServerName your_domain_or_IP
      ErrorLog ${APACHE_LOG_DIR}/error.log
      CustomLog ${APACHE_LOG_DIR}/access.log combined
    </VirtualHost>

    Replace "your_domain_or_IP" with the public IP number of your server. (I got the above from /etc/apache2/sites-available/dokuwiki.conf and I’m not certain it is necessary.) 

  2. Install php and extras:

    sudo apt install php php-xml php8.1-mbstring

  3. Install Dokuwiki by following the instructions at https://www.dokuwiki.org/install. Broadly, you fetch the file dokuwiki-stable.tgz by saying

    cd /var/www sudo wget https://download.dokuwiki.org/src/dokuwiki/dokuwiki-stable.tgz

    And then you’ll unpack the tgz file into /var/www/html using the commands

    cd /var/www/html sudo tar xvf /var/www/dokuwiki-stable.tgz -C /var/www/html 

    The -C arguments above tell tar to unpack the archive to the /var/www/html directory. You should then have a directory called something like /var/www/html/dokuwiki-2024-02-06a. Rename it to just ./dokuwiki:

    sudo mv  /var/www/html/dokuwiki-2024-02-06a /var/www/html/dokuwiki

  4. Now fetch the Upama plugin from Github:

    cd /var/www sudo git clone https://github.com/chchch/upama.git

  5. Install Upama. Charles explains what to do at the bottom of this page: https://github.com/chchch/upama . There’s no installation as such; all you do is copy the files to the right dokuwiki directories.

    To be more explicit, do the following:

    cd /var/www (where you now have an upama directory)

    Now copy the folders and files from the upama directory into the dokuwiki directory:

    sudo cp -r /var/www/upama/dokuwiki/* /var/www/html/dokuwiki/

    The folders that get copied are /var/www/upama/dokuwiki/data -> /var/www/html/dokuwiki/data /var/www/upama/dokuwiki/lib -> /var/www/html/dokuwiki/lib  

    One last thing:

    sudo touch /var/www/html/dokuwiki/data/pages/sidebar.txt  

    This creates the empty file /var/www/html/dokuwiki/data/pages/sidebar.txt

  6. Set some file permissions and ownership. This is a bit of a nightmare, and www.dokuwiki.org’s documentation is awful. But all your really need to do is this: sudo chmod -R 777 /var/www/html/dokuwiki/data/ sudo chmod -R 777 /var/www/html/dokuwiki/lib/ sudo chmod -R 777 /var/www/html/dokuwiki/conf/ sudo chown -R www-data:www-data /var/www/html/

  7. Next, some necessary apache stuff I got from https://forum.dokuwiki.org/d/9893-the-datadir-pages-at-data-pages-is-not-found/4 . We’ve already done the stuff up to Step C. Now edit the file apache2.conf. I use the editor vi; pick your favourite non-graphics editor.

    sudo vi /etc/apache2/apache2.conf 

     Find the lines

    <Directory /var/www/>
    ...
    </Directory>

    and below them add the following two new sections:

    <Directory /var/www/dokuwiki>
    order deny,allow
    allow from all
    </Directory>

    <LocationMatch "/(data|conf|bin|inc)/">
      order allow,deny
      deny from all
      satisfy all
    </LocationMatch>

    Then restart the apache server: sudo service apache2 restart Open a new browser tab and go to the page <my_IP_address>/dokuwiki/install.php This should open a page of dokuwiki settings. This page only appears the first time you invoke it; later, you get instructions on how to change things in a more low-level manner. At your dokuwiki page, log in and go to Admin/Configuration Manager. Amongst the initial “Basic” settings, find the setting for “template” and change it from “dokuwiki” to “saktumiva”. It looks like this:

     

    And go to the bottom of the screen and hit "save". 

  8. Stay with me. We’re almost done. The next thing is to add some TEI files of your edition.They are going to live in this directory:

      cd /var/www/html/dokuwiki/data/pages/wiki/  

    Create a file structure under wiki/ that makes sense to you. For example, sudo mkdir /var/www/html/dokuwiki/data/pages/wiki/Sakuntala/

    Copy your TEI files into ../Sakuntala/.  

    sudo cp /home/me/Documents/SaktutalaTEIfiles/* /var/www/html/dokuwiki/data/pages/wiki/Sakuntala

    Remember that the files need the extension .txt, even if they are xml files.

    You can also create a file start.txt in the ../Sakuntala/ directory that contains a nice starting page for your project. This must be written in dokuwiki syntax (cheatsheet).

  9. At this point, you should have a usable system. However, there’s a useful tweak. If you are going to upload your TEI files from your desktop to your new Saktumiva server by ftp, perhaps using Filezilla, you will want to change the ownership of files under ../Sakuntala/ so that your ftp identity can write files to that directory. sudo chown -R <me>:<me> /var/www/html/dokuwiki/data/pages/wiki/Sakuntala/

    where “<me>” is your Filezilla ftp login username. (You can set up users in Dokuwiki under Admin/User Manager).

  10. Other tweaks.
    • If your collation-generation times out, try upping the max execution in /etc/php8.1/apache/php.ini.
    • If your installation can't find symlinked files under directories, try adding the option +FollowSymLinks to  /etc/apache2/sites-enabled/000-default.conf:

      DocumentRoot /var/www/html
              <Directory />
              Options +FollowSymLinks
              AllowOverride None
              </Directory>
    • As a variant of point 9. above, you may prefer to use Saktumiva on your own laptop or desktop, rather than from a remote server.  If you want to link files from somewhere else on your disk into the Dokuwiki data/pages/wiki directory, you need to use hard links, not soft, symbolic links.  In Unix, ln <target> <name> not ln -s <target> <name>.   And if you want to be able to edit them through the Dokuwiki interface, say
      cd /var/www/html/dokuwiki/data/pages/wiki/Sakuntala/
      sudo chown -R <me>:www-data Sakuntala
      so that you are the "owner" but the "group" is still Apache.

-----------------------------------

*This installation guide by Christas Pontikis is very helpful: 

Dominik Wujastyk

June, August 2024

Wednesday, March 13, 2024

Bhartṛhari publications

The publication history of editions and translations of Bhartṛhari's Vākyapadīya and commentaries is complicated.  In Feb 2024, Christoph Vielle posted the following very useful collection of information about scanned volumes in this field.  Thank you, Christoph.

--


Ed. et transl. Subramania Iyer

Edition of Sanskrit text

Translations

+

Studies

 

Tuesday, September 12, 2023

Online issues of Indological journals

I repeatedly find my self searching for back issues of journals, and between searches I forget what I learned the first time.  Here are some notes to myself, to remind myself what can be found online.  I'm writing this in April 2018, so moving walls will have moved in future years.
  • Indo-Iranian Journal
  • Indologica Taurinensia
  • Journal asiatique (with gaps):
  • Journal of the Ganganath Jha Research Institute (now Ganganath Jha Campus)
  • Journal of Indian and Buddhist Studies (Indogaku Bukkyogaku Kenkyu)
  • JIABS: Journal of the International Association of Buddhist Studies 

  • Journal of the Asiatic Society of Bengal
  • Journal of the Royal Asiatic of Bengal
  • Journal of the Asiatic Society of Bombay
  • Journal of the Royal Asiatic Society
    • 1824-1834 JSTOR (Transactions of the Royal Asiatic Society of Great Britain and Ireland)
    • 1834-1990 JSTOR (The Journal of the Royal Asiatic Society of Great Britain and Ireland
    • 1991-2013 JSTOR (Journal of the Royal Asiatic Society)
  • Journal of the Pali Text Society
  • Orientalia Suecana
  • Philosophy East and West 1951-2014
  • The Pandit many issues identified and linked at Shreevatsa's blog.
  • Transactions of the Philological Society  
    • many issues from 1854-1946 identified and linked by U. Penn.
  • Wiener Zeitschrift für die Kunde Süd- und Ostasiens
    • 1991-20?? JSTOR , five-year moving wall.
  • Zeitschrift der Deutschen Morgenländischen Gesellschaft
    • 1847-present (I believe) JSTOR; MLU (1847-2013, more coming).