Renaming a Cell Browser dataset

From Genecats
Jump to navigationJump to search

These go through how to change a dataset’s short name, but not have to go through the often lengthy process of rebuilding a dataset from scratch. It assumes that you are carrying out the steps on hgwdev to change the short name for a dataset on cells-test.

Note: a dataset’s short name should pretty much never be changed after being pushed to the main site. People bookmark things and URLs make their way into publications and we want to try our hardest not to break those.

First, rename the directory in datasets:

cd /hive/data/inside/cells/datasets/ 
mv {old_name} {new_name}

Then, rename the directory in htdocs-cells

cd /usr/local/apache/htdocs-cells/
mv {old_name} {new_name}

Best to do this soon after you rename the other dir so that the same mv command isn’t too far back in your history.

Finally, rebuild the dataset:

cd /usr/local/apache/htdocs-cells/{new_name}
cbBuild -o alpha

This is necessary because the old name is still present in various dataset.json files, so rebuilding will ensure that all instances of the old name are replaced with the new ones. If it's a collection, you'll need to rebuild each of the child datasets.