Line |
Branch |
Exec |
Source |
1 |
|
|
/** |
2 |
|
|
* This file is part of the CernVM File System. |
3 |
|
|
*/ |
4 |
|
|
|
5 |
|
|
#ifndef CVMFS_PUBLISH_CMD_COMMIT_H_ |
6 |
|
|
#define CVMFS_PUBLISH_CMD_COMMIT_H_ |
7 |
|
|
|
8 |
|
|
#include <string> |
9 |
|
|
#include <vector> |
10 |
|
|
|
11 |
|
|
#include "publish/command.h" |
12 |
|
|
|
13 |
|
|
namespace publish { |
14 |
|
|
|
15 |
|
|
class CmdCommit : public Command { |
16 |
|
|
public: |
17 |
|
✗ |
virtual std::string GetName() const { return "commit"; } |
18 |
|
|
|
19 |
|
✗ |
virtual std::string GetBrief() const { |
20 |
|
✗ |
return "Commit changes made inside the ephemeral shell"; |
21 |
|
|
} |
22 |
|
|
|
23 |
|
✗ |
virtual std::string GetDescription() const { |
24 |
|
✗ |
return "Commit new content from the ephemeral shell"; |
25 |
|
|
} |
26 |
|
|
|
27 |
|
✗ |
virtual std::string GetUsage() const { |
28 |
|
✗ |
return "[options] <repository name>"; |
29 |
|
|
} |
30 |
|
|
|
31 |
|
✗ |
virtual ParameterList GetParams() const { |
32 |
|
✗ |
ParameterList p; |
33 |
|
✗ |
p.push_back(Parameter::Optional( |
34 |
|
|
"repo-config", 'x', "repository configuration", |
35 |
|
|
"Path to the configuration of the repository gateway")); |
36 |
|
✗ |
return p; |
37 |
|
|
} |
38 |
|
|
|
39 |
|
✗ |
virtual std::vector<std::string> GetExamples() const { |
40 |
|
✗ |
std::vector<std::string> e; |
41 |
|
✗ |
e.push_back( |
42 |
|
|
"commit myrepo.cvmfs.io " |
43 |
|
|
"# commit changes to myrepo.cvmfs.io"); |
44 |
|
✗ |
return e; |
45 |
|
|
} |
46 |
|
|
|
47 |
|
|
virtual int Main(const Options &options); |
48 |
|
|
}; |
49 |
|
|
|
50 |
|
|
} // namespace publish |
51 |
|
|
|
52 |
|
|
#endif // CVMFS_PUBLISH_CMD_COMMIT_H_ |
53 |
|
|
|