Page Menu
Home
Software Heritage
Search
Configure Global Search
Log In
Files
F9696542
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
6 KB
Subscribers
None
View Options
diff --git a/common/modules/deposit.org b/common/modules/deposit.org
index 1b44e2c..7f5763d 100644
--- a/common/modules/deposit.org
+++ b/common/modules/deposit.org
@@ -1,184 +1,184 @@
#+COLUMNS: %40ITEM %10BEAMER_env(Env) %9BEAMER_envargs(Env Args) %10BEAMER_act(Act) %4BEAMER_col(Col) %10BEAMER_extra(Extra) %8BEAMER_opt(Opt)
#+INCLUDE: "prelude.org" :minlevel 1
# Requirements:
#
#+LATEX_HEADER_EXTRA: \usepackage{tikz}
#+LATEX_HEADER_EXTRA: \usetikzlibrary{arrows,shapes}
#+LATEX_HEADER_EXTRA: \definecolor{swh-orange}{RGB}{254,205,27}
#+LATEX_HEADER_EXTRA: \definecolor{swh-red}{RGB}{226,0,38}
#+LATEX_HEADER_EXTRA: \definecolor{swh-green}{RGB}{77,181,174}
* Deposit
:PROPERTIES:
:CUSTOM_ID: main
:END:
** Pushing source code to Software Heritage
:PROPERTIES:
:CUSTOM_ID: overview
:END:
**** Deposit service
- complement regular (pull) crawling of forges and distributions
- restricted access (i.e., not a warez dumpster!)
- early prototype at: *\url{https://deposit.softwareheritage.org/}*
**** Tech bits
- *SWORD* 2.0 compliant server, for digital repositories interoperability
- RESTful API for deposit and monitoring, with CLI wrapper
** Prepare a deposit
:PROPERTIES:
:CUSTOM_ID: prepare
:END:
*** Prepare source code tarball
#+BEGIN_SRC
$ tar cvf je-suis-gpl.tgz /path/to/je-suis-gpl/
#+END_SRC
#+BEAMER: \pause
*** Associate metadata
#+BEAMER: \scriptsize
#+BEGIN_SRC
$ cat > je-suis-gpl.tgz.metadata.xml
<?xml version="1.0"?>
<entry xmlns="http://www.w3.org/2005/Atom"
xmlns:codemeta="https://doi.org/10.5063/SCHEMA/CODEMETA-2.0">
<title>Je suis GPL</title>
<external_identifier>ext-id</external_identifier>
<codemeta:url>https://forge.softwareheritage.org/source/jesuisgpl/</codemeta:url>
<codemeta:author>
<codemeta:name>Stefano Zacchiroli</codemeta:name>
<codemeta:jobTitle>Maintainer</codemeta:affiliation>
</codemeta:author>
</entry>
^D
#+END_SRC
** Send a deposit
:PROPERTIES:
:CUSTOM_ID: send
:END:
***
#+BEGIN_SRC
$ swh-deposit --username 'name' --password 'pass' \
--archive je-suis-gpl.tgz
#+END_SRC
#+BEAMER: \pause
#+BEGIN_SRC
{
'deposit_id': '11',
'deposit_status': 'deposited',
'deposit_date': 'Jan. 30, 2018, 9:37 a.m.'
}
#+END_SRC
** Multipart deposit
:PROPERTIES:
:CUSTOM_ID: multipart
:END:
***
#+BEAMER: \scriptsize
#+BEGIN_SRC
$ swh-deposit --username 'name' --password 'secret' \
--partial \
--archive the-bulk-of-it.tar.gz
#+END_SRC
#+BEAMER: \pause
#+BEGIN_SRC
{
'deposit_id': '11',
'deposit_status': 'partial',
'deposit_date': 'Jan. 30, 2018, 9:37 a.m.'
}
#+END_SRC
#+BEAMER: \pause
***
#+BEAMER: \scriptsize
#+BEGIN_SRC
$ swh-deposit --username 'name' --password 'secret' \
--partial \ # omit this to finalize
--deposit-id 11 --archive addendum.tar.gz
#+END_SRC
#+BEAMER: \pause
***
#+BEAMER: \scriptsize
#+BEGIN_SRC
$ swh-deposit --username 'name' --password 'secret' \
--deposit-id 11 --archive last-touch.tar.gz
#+END_SRC
** Replace previous archive and/or metadata
:PROPERTIES:
:CUSTOM_ID: override
:END:
***
#+BEAMER: \scriptsize
#+BEGIN_SRC
$ swh-deposit --username 'name' --password 'secret' \
--deposit-id 11 \
--archive updated-je-suis-gpl.tar.gz \
--replace
#+END_SRC
#+BEAMER: \pause
#+BEAMER: \scriptsize
#+BEGIN_SRC
{
'deposit_id': '11',
'deposit_status': 'deposited',
'deposit_date': 'Jan. 30, 2018, 9:37 a.m.'
}
#+END_SRC
** Ingestion status
:PROPERTIES:
:CUSTOM_ID: status
:END:
\tikzstyle{fail} = [draw, thin, fill=swh-red!80!swh-orange, minimum height=1.5em]
\tikzstyle{processing} = [draw, thin, fill=swh-orange!100, minimum height=1.5em]
\tikzstyle{success} = [draw, thin, fill=swh-green!80!swh-orange, minimum height=1.5em]
\begin{figure}
\begin{tikzpicture}[node distance=1.8cm, auto,>=latex', thick]
% We need to set at bounding box first. Otherwise the diagram
% will change position for each frame.
%\path[use as bounding box] (-1,0) rectangle (10,-2);
\path[->]<1-> node[processing] (partial) {partial}
node[success, right of=partial] (deposited) {deposited}
(partial) edge node {} (deposited)
node[processing, right of=deposited] (checking) {}
(deposited) edge node {} (checking)
node[success, right of=checking] (verified) {verified}
node[fail, below of=checking] (rejected) {rejected}
(checking) edge node {} (verified)
edge node[swap] {} (rejected)
node[processing, right of=verified] (loading) {}
node[success, right of=loading] (done) {done}
node[fail, below of=loading] (failed) {failed}
(verified) edge node {} (loading)
(loading) edge node {} (failed)
(loading) edge node {} (done);
\end{tikzpicture}
\end{figure}
#+BEAMER: \pause
***
#+BEAMER: \footnotesize
#+BEGIN_SRC
$ swh-deposit --username 'name' --pass 'secret' \
--deposit-id '11' --status
#+END_SRC
#+BEAMER: \pause
#+BEGIN_SRC
{
'deposit_id': 11,
'deposit_status': 'done',
'deposit_status_detail': The deposit has been successfully loaded
into the Software Heritage archive',
'deposit_swh_id': 'swh:1:rev:608757ea9bd8494d729732cc9a414948c160bd3c'
}
#+END_SRC
-** Retrieve a deposit
+** Access a deposit
:PROPERTIES:
- :CUSTOM_ID: download
+ :CUSTOM_ID: access
:END:
-*** Deposit completed and loaded
- The deposit was succesfully pushed and integrated into the archive.\\
- You can browse it using the deposit's /swh-id/:
- - *archive.softwareheritage.org/browse/<swh-id>*
- #+BEAMER: \pause
-*** Download
- Now we want to download the content with the
- #+BEAMER: \huge
- *Vault*
+ After ingestion a deposit becomes an integral, permanent part of the
+ Software Heritage archive.
+
+ - it has a *persistent identifier*
+ - e.g., =swh:1:rev:608757ea9bd8494d729732cc9a414948c160bd3c=
+ - it can be *browsed* online at https://archive.softwareheritage.org/
+ - e.g.,
+ https://archive.softwareheritage.org/browse/swh:1:rev:608757ea9bd8494d729732cc9a414948c160bd3c
+ - it can be bulk *downloaded* using the Software Heritage Vault
File Metadata
Details
Attached
Mime Type
text/x-diff
Expires
Mon, Aug 18, 8:32 PM (2 h, 22 m ago)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
3463927
Attached To
rMSLD Slides and presentation material
Event Timeline
Log In to Comment