2018-08-24 11:03:35 +02:00
|
|
|
//@flow
|
2018-09-05 14:45:22 +02:00
|
|
|
import React from "react";
|
|
|
|
|
import type { Repository } from "@scm-manager/ui-types";
|
2018-08-24 11:03:35 +02:00
|
|
|
|
|
|
|
|
type Props = {
|
2018-09-05 14:45:22 +02:00
|
|
|
repository: Repository
|
2018-08-24 11:03:35 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
class ProtocolInformation extends React.Component<Props> {
|
|
|
|
|
|
|
|
|
|
render() {
|
|
|
|
|
const { repository } = this.props;
|
|
|
|
|
if (!repository._links.httpProtocol) {
|
|
|
|
|
return null;
|
|
|
|
|
}
|
|
|
|
|
return (
|
|
|
|
|
<div>
|
|
|
|
|
<h4>Checkout the repository</h4>
|
|
|
|
|
<pre>
|
|
|
|
|
<code>svn checkout {repository._links.httpProtocol.href}</code>
|
|
|
|
|
</pre>
|
|
|
|
|
</div>
|
|
|
|
|
);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
export default ProtocolInformation;
|