Skip to content

Commit

Permalink
add info on ignoring directories when using nextcloud virtual files
Browse files Browse the repository at this point in the history
  • Loading branch information
gmcdonald-sfg committed Mar 15, 2024
1 parent bf071cd commit d878122
Show file tree
Hide file tree
Showing 39 changed files with 2,255 additions and 1,030 deletions.
18 changes: 18 additions & 0 deletions 08_workflow_platforms.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -191,9 +191,13 @@ There are generally three approaches for syncing and streaming files to your loc
- Pros
- Virtual files operate similarly to “streaming” using the Google Drive app. Virtual files take up very little hard drive space on your local machine, and are rather just a pointer to the actual file, which is stored on GRIT.
- You will be able to view the full emLab directory structure on your local machine. The entire contents of the emLab directory will always be available and up-to-date.
- If you do not wish to see the *entire* emLab directory on your local machine, you have the option selectively choose to ignore particular directories. For example, you may not need to see `projects/archived-projects` on your local machine (besides, you can always see it on the [Nextcloud browser interface](https://nextcloud.grit.ucsb.edu/index.php/apps/files)! )


- Cons
- Virtual files have a .nextcloud extension, since they are just a pointer file. This means for instance that they cannot be directly read into R. To open a virtual file on your local machine, you need to first double-click on it (or right-click on it and say “Make always available locally”). Once you’ve done this, the virtual file is now available on your local machine, but it also now takes up hard drive space.
- Since the entire emLab directory has hundreds of thousands of files across hundreds of directories, it will take some time for the Nextcloud desktop app to sync all of these virtual files. This process will take a long time when you first connect to the emLab directory (up to several days). However, once the initial sync of virtual files is complete, this should not need to occur again, and only new/modified virtual files will need to be synced.
- Virtual files are not available offline without internet access.

**Option 2: Selectively “sync” only a subset of directories.** Using this approach, each individual manually selects which directories they want to sync to their local machine. For example, you may choose to only sync the project directories you are actively working with. The emLab Nextcloud directory is very large (multiple TB), so you do not want to do a full sync of the entire emLab directory on your local machine.

Expand Down Expand Up @@ -263,6 +267,20 @@ Linux

![](images/nextcloud11.png)

**Step 9:** If you are using virtual files and streaming the entire emLab directory, you may wish to ignore particular directories. To do so:

- Open up the Nextcloud desktop app settings, click the 3 dots, and click "Edit Ignored Files"

![](images/nextcloud_ignore_1.png)

- Click "Add" and then enter the new ignore pattern. For example, enter the pattern `projects/archived-projects/*` to ignore all files in the `projects/archived-projects` directory. If you also wish to hide the directory name itself, add a second pattern that is simply `projects/archived-projects`. This directory will no longer appear on your local machine.

![](images/nextcloud_ignore_2.png)

- If at any point in the future you wish to see these directories again on your local machine, you can simply remove the ignore pattern from this list.

**Important Note!** We are currently in an active data migration process moving from Google Shared Drive to GRIT. We are "staging" files in a directory called `emLab/staging`. We *highly* recommend that you add `emLab/staging` and `emLab/staging*` to your ignored file lists. This will ensure that this staging directory cannot be seen or modified on your local machine. Once the migration process is complete, we will be moving all directories into their appropriate locations under the main `emLab` directory and will delete the staging directory.

##### File option 2: Syncing a subset of directories

**Step 1:** After logging in, you will be brought back to the Nextcloud app. Click “Choose what to sync”. This will bring you to a screen that contains all emLab directories. You may now select the subset of directories you wish to sync. Click “Add Sync Connection” after you have selected the appropriate directories.
Expand Down
372 changes: 372 additions & 0 deletions docs/404.html

Large diffs are not rendered by default.

148 changes: 94 additions & 54 deletions docs/code-of-conduct.html

Large diffs are not rendered by default.

148 changes: 94 additions & 54 deletions docs/communications-and-outreach.html

Large diffs are not rendered by default.

156 changes: 98 additions & 58 deletions docs/emlab-values-and-culture.html

Large diffs are not rendered by default.

352 changes: 204 additions & 148 deletions docs/emlab-workflow-and-platforms.html

Large diffs are not rendered by default.

164 changes: 102 additions & 62 deletions docs/expectations.html

Large diffs are not rendered by default.

180 changes: 110 additions & 70 deletions docs/feedback-and-learning.html

Large diffs are not rendered by default.

232 changes: 136 additions & 96 deletions docs/housekeeping.html

Large diffs are not rendered by default.

Binary file modified docs/images/nextcloud16.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/images/nextcloud_ignore_1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/images/nextcloud_ignore_2.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
151 changes: 96 additions & 55 deletions docs/index.html

Large diffs are not rendered by default.

2 changes: 2 additions & 0 deletions docs/libs/anchor-sections-1.1.0/anchor-sections-hash.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
/* Styles for section anchors */
a.anchor-section::before {content: '#';font-size: 80%;}
4 changes: 4 additions & 0 deletions docs/libs/anchor-sections-1.1.0/anchor-sections.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
/* Styles for section anchors */
a.anchor-section {margin-left: 10px; visibility: hidden; color: inherit;}
.hasAnchor:hover a.anchor-section {visibility: visible;}
ul > li > .anchor-section {display: none;}
11 changes: 11 additions & 0 deletions docs/libs/anchor-sections-1.1.0/anchor-sections.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
document.addEventListener('DOMContentLoaded', function () {
// If section divs is used, we need to put the anchor in the child header
const headers = document.querySelectorAll("div.hasAnchor.section[class*='level'] > :first-child")

headers.forEach(function (x) {
// Add to the header node
if (!x.classList.contains('hasAnchor')) x.classList.add('hasAnchor')
// Remove from the section or div created by Pandoc
x.parentElement.classList.remove('hasAnchor')
})
})
8 changes: 7 additions & 1 deletion docs/libs/gitbook-2.6.7/css/plugin-bookdown.css
Original file line number Diff line number Diff line change
Expand Up @@ -90,10 +90,16 @@ div.theorem, div.lemma, div.corollary, div.proposition, div.conjecture {
span.theorem, span.lemma, span.corollary, span.proposition, span.conjecture {
font-style: normal;
}
div.proof:after {
div.proof>*:last-child:after {
content: "\25a2";
float: right;
}
.header-section-number {
padding-right: .5em;
}
#header .multi-author {
margin: 0.5em 0 -0.5em 0;
}
#header .date {
margin-top: 1.5em;
}
18 changes: 18 additions & 0 deletions docs/libs/gitbook-2.6.7/css/plugin-clipboard.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
div.sourceCode {
position: relative;
}

.copy-to-clipboard-button {
position: absolute;
right: 0;
top: 0;
visibility: hidden;
}

.copy-to-clipboard-button:focus {
outline: 0;
}

div.sourceCode:hover > .copy-to-clipboard-button {
visibility: visible;
}
11 changes: 11 additions & 0 deletions docs/libs/gitbook-2.6.7/css/plugin-fontsettings.css
Original file line number Diff line number Diff line change
Expand Up @@ -44,13 +44,24 @@
line-height: 30px;
font-size: 1em;
}

/* sidebar transition background */
div.book.color-theme-1 {
background: #f3eacb;
}
.book.color-theme-1 .book-body {
color: #704214;
background: #f3eacb;
}
.book.color-theme-1 .book-body .page-wrapper .page-inner section {
background: #f3eacb;
}

/* sidebar transition background */
div.book.color-theme-2 {
background: #1c1f2b;
}

.book.color-theme-2 .book-body {
color: #bdcadb;
background: #1c1f2b;
Expand Down
11 changes: 7 additions & 4 deletions docs/libs/gitbook-2.6.7/css/style.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion docs/libs/gitbook-2.6.7/js/app.min.js

Large diffs are not rendered by default.

7 changes: 7 additions & 0 deletions docs/libs/gitbook-2.6.7/js/clipboard.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

18 changes: 16 additions & 2 deletions docs/libs/gitbook-2.6.7/js/plugin-bookdown.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,18 @@ gitbook.require(["gitbook", "lodash", "jQuery"], function(gitbook, _, $) {
}
});

// add the View button (file view on Github)
var view = config.view;
if (view && view.link) gitbook.toolbar.createButton({
icon: 'fa fa-eye',
label: view.text || 'View Source',
position: 'left',
onClick: function(e) {
e.preventDefault();
window.open(view.link);
}
});

// add the Download button
var down = config.download;
var normalizeDownload = function() {
Expand Down Expand Up @@ -72,7 +84,7 @@ gitbook.require(["gitbook", "lodash", "jQuery"], function(gitbook, _, $) {
if (config.search !== false) info.push('f: Toggle search input ' +
'(use <up>/<down>/Enter in the search input to navigate through search matches; ' +
'press Esc to cancel search)');
gitbook.toolbar.createButton({
if (config.info !== false) gitbook.toolbar.createButton({
icon: 'fa fa-info',
label: 'Information about the toolbar',
position: 'left',
Expand All @@ -85,6 +97,8 @@ gitbook.require(["gitbook", "lodash", "jQuery"], function(gitbook, _, $) {
// highlight the current section in TOC
var href = window.location.pathname;
href = href.substr(href.lastIndexOf('/') + 1);
// accentuated characters need to be decoded (#819)
href = decodeURIComponent(href);
if (href === '') href = 'index.html';
var li = $('a[href^="' + href + location.hash + '"]').parent('li.chapter').first();
var summary = $('ul.summary'), chaps = summary.find('li.chapter');
Expand Down Expand Up @@ -133,7 +147,7 @@ gitbook.require(["gitbook", "lodash", "jQuery"], function(gitbook, _, $) {
if (typeof pos !== 'undefined') summary.scrollTop(pos);

// highlight the TOC item that has same text as the heading in view as scrolling
if (toc && toc.scroll_highlight !== false) (function() {
if (toc && toc.scroll_highlight !== false && li.length > 0) (function() {
// scroll the current TOC item into viewport
var ht = $(window).height(), rect = li[0].getBoundingClientRect();
if (rect.top >= ht || rect.top <= 0 || rect.bottom <= 0) {
Expand Down
33 changes: 33 additions & 0 deletions docs/libs/gitbook-2.6.7/js/plugin-clipboard.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
gitbook.require(["gitbook", "jQuery"], function(gitbook, $) {

var copyButton = '<button type="button" class="copy-to-clipboard-button" title="Copy to clipboard" aria-label="Copy to clipboard"><i class="fa fa-copy"></i></button>';
var clipboard;

gitbook.events.bind("page.change", function() {

if (!ClipboardJS.isSupported()) return;

// the page.change event is thrown twice: before and after the page changes
if (clipboard) {
// clipboard is already defined but we are on the same page
if (clipboard._prevPage === window.location.pathname) return;
// clipboard is already defined and url path change
// we can deduct that we are before page changes
clipboard.destroy(); // destroy the previous events listeners
clipboard = undefined; // reset the clipboard object
return;
}

$(copyButton).prependTo("div.sourceCode");

clipboard = new ClipboardJS(".copy-to-clipboard-button", {
text: function(trigger) {
return trigger.parentNode.textContent;
}
});

clipboard._prevPage = window.location.pathname

});

});
Loading

0 comments on commit d878122

Please sign in to comment.