return ret;
}
+static PyObject *client_mkdir(PyObject *self, PyObject *args)
+{
+ PyObject *paths, *revprops = NULL;
+ bool make_parents=false;
+ apr_pool_t *temp_pool;
+ svn_commit_info_t *commit_info = NULL;
+ PyObject *ret;
+ apr_array_header_t *apr_paths;
+ apr_hash_t *hash_revprops;
+ ClientObject *client = (ClientObject *)self;
+
+ if (!PyArg_ParseTuple(args, "O|bO", &paths, &make_parents, &revprops))
+ return NULL;
+
+ temp_pool = Pool(NULL);
+ if (temp_pool == NULL)
+ return NULL;
+ if (!path_list_to_apr_array(temp_pool, paths, &apr_paths)) {
+ apr_pool_destroy(temp_pool);
+ return NULL;
+ }
+
+ if (revprops != NULL && !PyDict_Check(revprops)) {
+ apr_pool_destroy(temp_pool);
+ PyErr_SetString(PyExc_TypeError, "Expected dictionary with revision properties");
+ return NULL;
+ }
+
+#if ONLY_SINCE_SVN(1, 5)
+ if (revprops != NULL && revprops != Py_None) {
+ hash_revprops = prop_dict_to_hash(temp_pool, revprops);
+ if (hash_revprops == NULL) {
+ apr_pool_destroy(temp_pool);
+ return NULL;
+ }
+ } else {
+ hash_revprops = NULL;
+ }
+
+ RUN_SVN_WITH_POOL(temp_pool, svn_client_mkdir3(&commit_info,
+ apr_paths,
+ make_parents, hash_revprops, client->client, temp_pool));
+#else
+ if (make_parents) {
+ PyErr_SetString(PyExc_ValueError,
+ "make_parents not supported against svn 1.4");
+ apr_pool_destroy(temp_pool);
+ return NULL;
+ }
+ if (revprops != Py_None) {
+ PyErr_SetString(PyExc_ValueError,
+ "revprops not supported against svn 1.4");
+ apr_pool_destroy(temp_pool);
+ return NULL;
+ }
+
+ RUN_SVN_WITH_POOL(temp_pool, svn_client_mkdir2(&commit_info,
+ apr_paths,
+ client->client, temp_pool));
+#endif
+
+ ret = py_commit_info_tuple(commit_info);
+
+ apr_pool_destroy(temp_pool);
+
+ return ret;
+}
+
+
+
static PyObject *client_copy(PyObject *self, PyObject *args, PyObject *kwargs)
{
char *src_path, *dst_path;
{ "update", client_update, METH_VARARGS, "S.update(path, rev=None, recurse=True, ignore_externals=False) -> list of revnums" },
{ "list", (PyCFunction)client_list, METH_VARARGS|METH_KEYWORDS, "S.list(path, peg_revision, depth, dirents=ra.DIRENT_ALL, revision=None) -> list of directory entries" },
{ "diff", (PyCFunction)client_diff, METH_VARARGS|METH_KEYWORDS, "S.diff(rev1, rev2, path1=None, path2=None, relative_to_dir=None, diffopts=[], encoding=\"utf-8\", ignore_ancestry=True, no_diff_deleted=True, ignore_content_type=False) -> unified diff as a string" },
+ { "mkdir", (PyCFunction)client_mkdir, METH_VARARGS|METH_KEYWORDS, "S.mkdir(paths, make_parents=False, revprops=None) -> (revnum, date, author)" },
{ NULL, }
};