100+ results for 'php mkdir'
Not the results you expected?
mod_auth_basic.mak (https://github.com/Pedlar/pypanel-httpd.git) Makefile · 353 lines
test-dropin.sh (https://gitlab.com/parabola/user_lukeshu_systemd) Shell · 274 lines
28 ExecStart=/bin/sleep 100000
29 EOF
30 mkdir -p /{etc,run,usr/lib}/systemd/system/$1.service.d
31 mkdir -p /etc/systemd/system/$1.service.{wants,requires}
32 mkdir -p /run/systemd/system/$1.service.{wants,requires}
33 mkdir -p /usr/lib/systemd/system/$1.service.{wants,requires}
141 echo "*** test 2"
142 create_services a x y
143 mkdir -p /etc/systemd/system/a1.service.wants/
144 ln -sf a.service /etc/systemd/system/a1.service
145 ln -sf ../x.service /etc/systemd/system/a.service.wants/
test_dir_m17n.rb (https://github.com/yoozoosato/ruby.git) Ruby · 239 lines
FilesystemTest.php (https://gitlab.com/yousafsyed/easternglamor) PHP · 240 lines
1 <?php
3 /*
119 * @group GH-1339
120 */
121 public function testRemoveDirectoryPhp()
122 {
123 $tmp = sys_get_temp_dir();
124 @mkdir($tmp . "/composer_testdir/level1/level2", 0777, true);
125 file_put_contents($tmp . "/composer_testdir/level1/level2/hello.txt", "hello world");
127 $fs = new Filesystem;
128 $this->assertTrue($fs->removeDirectoryPhp($tmp . "/composer_testdir"));
129 $this->assertFalse(file_exists($tmp . "/composer_testdir/level1/level2/hello.txt"));
130 }
Filesystem.php (https://gitlab.com/techniconline/kmc) PHP · 426 lines
Clover.php (https://gitlab.com/madebycloud/derekman) PHP · 290 lines
1 <?php
2 /*
3 * This file is part of the PHP_CodeCoverage package.
4 *
5 * (c) Sebastian Bergmann <sebastian@phpunit.de>
6 *
7 * For the full copyright and license information, please view the LICENSE
11 /**
12 * Generates a Clover XML logfile from an PHP_CodeCoverage object.
13 *
14 * @category PHP
15 * @package CodeCoverage
16 * @author Sebastian Bergmann <sebastian@phpunit.de>
17 * @copyright Sebastian Bergmann <sebastian@phpunit.de>
test.php (https://github.com/activeingredient/ezComponents.git) PHP · 301 lines
1 <?php
2 /**
3 * @copyright Copyright (C) 2005-2010 eZ Systems AS. All rights reserved.
245 $tempDir = $this->createTempDir( get_class( $this ) );
246 $path = $tempDir . DIRECTORY_SEPARATOR . $value;
247 mkdir( $path );
248 chmod( $path, 0 );
280 $tempDir = $this->createTempDir( get_class( $this ) );
281 $path = $tempDir . DIRECTORY_SEPARATOR . $value;
282 mkdir( $path );
283 chmod( $path, 0444 );
test.php (https://github.com/F5/zetacomponents.git) PHP · 297 lines
1 <?php
2 /**
3 *
241 $tempDir = $this->createTempDir( get_class( $this ) );
242 $path = $tempDir . DIRECTORY_SEPARATOR . $value;
243 mkdir( $path );
244 chmod( $path, 0 );
276 $tempDir = $this->createTempDir( get_class( $this ) );
277 $path = $tempDir . DIRECTORY_SEPARATOR . $value;
278 mkdir( $path );
279 chmod( $path, 0444 );
files.php (https://gitlab.com/webbroteam/satisfaction-mvc) PHP · 306 lines
13 */
15 namespace phpFastCache\Drivers;
17 use phpFastCache\Core\DriverAbstract;
18 use phpFastCache\Exceptions\phpFastCacheDriverException;
20 /**
28 * phpFastCache_files constructor.
29 * @param array $config
30 * @throws phpFastCacheDriverException
31 */
32 public function __construct($config = array())
57 * @param bool $skip
58 * @return string
59 * @throws phpFastCacheDriverException
60 */
61 private function getFilePath($keyword, $skip = false)
test-gsktable.c (https://github.com/davebenson/gsk.git) C · 263 lines
Files.php (https://github.com/jaws-project/jaws.git) PHP · 282 lines
test.js (https://gitlab.com/Jerry-Lau/buble) JavaScript · 303 lines
given.php (https://gitlab.com/Blueprint-Marketing/wp-cli) PHP · 156 lines
1 <?php
3 use Behat\Gherkin\Node\PyStringNode,
21 $content = (string) $content . "\n";
22 $full_path = $world->variables['RUN_DIR'] . "/$path";
23 Process::create( \WP_CLI\utils\esc_cmd( 'mkdir -p %s', dirname( $full_path ) ) )->run_check();
24 file_put_contents( $full_path, $content );
25 }
32 );
34 $steps->Given( '/^wp-config\.php$/',
35 function ( $world ) {
36 $world->create_config();
65 $steps->Given( '/^these installed and active plugins:$/',
66 function( $world, $stream ) {
67 $plugins = implode( ' ', array_map( 'trim', explode( PHP_EOL, (string)$stream ) ) );
68 $world->proc( "wp plugin install $plugins --activate" )->run_check();
69 }
Protocol.cc (https://github.com/ak2consulting/hypertable.git) C++ · 342 lines
upload.php (https://github.com/mmeester/droparea.git) PHP · 124 lines
1 <?php
3 // Maximum file size
27 $folder = $headers['x-param-folder'] ? $headers['x-param-folder'] . '/' : '';
28 if ($folder && !is_dir($folder))
29 mkdir($folder);
31 // File type control
51 // File path
52 $path = str_replace('upload.php', '', $_SERVER['SCRIPT_NAME']);
53 // Image tag
54 $r->filename = $filename;
57 echo json_encode($r);
59 // Image resize function with php + gd2 lib
60 function imageresize($source, $destination, $width = 0, $height = 0, $crop = false, $quality = 80) {
61 $quality = $quality ? $quality : 80;
pmDownloadTest.php (https://bitbucket.org/IshaDakota/programdb.git) PHP · 108 lines
1 <?php
3 /**
6 class pmDownloadCase extends Drush_CommandTestCase {
7 public function testPmDownload() {
8 $this->drush('pm-download', array('devel'), array('cache' => NULL, 'skip' => NULL)); // No FirePHP
9 $this->assertFileExists(UNISH_SANDBOX . '/devel/README.txt');
10 }
20 $devel_options = array(
21 'cache' => NULL,
22 'skip' => NULL, // No FirePHP
23 'invoke' => NULL, // Invoke from script: do not verify options
24 );
42 $path_stage = "$root/sites/$uri";
43 // gets created by --use-site-dir above,
44 // mkdir("$path_stage/modules");
45 $options = $devel_options;
46 $this->drush('pm-download', array('devel'), $options, NULL, $path_stage);
GenerateProxiesCommand.php (https://bitbucket.org/rkovcs/bigfish_test.git) PHP · 112 lines
1 <?php
2 /*
3 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
79 if ( ! is_dir($destPath)) {
80 mkdir($destPath, 0777, true);
81 }
96 foreach ($metadatas as $metadata) {
97 $output->write(
98 sprintf('Processing entity "<info>%s</info>"', $metadata->name) . PHP_EOL
99 );
100 }
105 // Outputting information message
106 $output->write(PHP_EOL . sprintf('Proxy classes generated to "<info>%s</INFO>"', $destPath) . PHP_EOL);
107 } else {
108 $output->write('No Metadata Classes to process.' . PHP_EOL);
Printer.php (https://gitlab.com/Loupak/Laravel-GRUD) PHP · 172 lines
3 * This file is part of PHPUnit.
4 *
5 * (c) Sebastian Bergmann <sebastian@phpunit.de>
6 *
7 * For the full copyright and license information, please view the LICENSE
58 $this->out = fsockopen($out[0], $out[1]);
59 } else {
60 if (strpos($out, 'php://') === false &&
61 !is_dir(dirname($out))) {
62 mkdir(dirname($out), 0777, true);
128 }
129 } else {
130 if (PHP_SAPI != 'cli' && PHP_SAPI != 'phpdbg') {
131 $buffer = htmlspecialchars($buffer);
132 }
builtins_file.idl.php (https://github.com/Tener/pfff.git) PHP · 99 lines
1 <?php
2 // THIS IS AUTOGENERATED BY builtins_php.ml
86 function diskfreespace($directory) { }
87 function disk_total_space($directory) { }
88 function mkdir($pathname, $mode = 0777, $recursive = false, $context = null) { }
89 function rmdir($dirname, $context = null) { }
90 function dirname($path) { }
Rakefile (https://gitlab.com/pwgd/false-start-pwgd) Rakefile · 133 lines
9 DEFAULT_DIR = "web/sites/default"
10 PROFILE = "pwgd"
11 SETTINGS_SOURCE_REL = "provisioning/settings.#{ENV['ENVIRONMENT']}.php"
12 SETTINGS_TARGET_REL = "#{DEFAULT_DIR}/settings.local.php"
84 task :build do
85 rm_r BUILD_DIR
86 mkdir_p BUILD_DIR
87 sh "git archive HEAD | tar -x -C #{BUILD_DIR}"
88 sh "composer install -d #{BUILD_DIR} --no-dev"
128 desc "Run performance tests."
129 task :performance => [:vendor] do
130 sh "./vendor/bin/phpunit --bootstrap ./vendor/autoload.php --log-junit reports/performance.xml tests/"
131 end
132 end
ExtendedFileStream.php (https://gitlab.com/Isaki/le331.fr) PHP · 194 lines
1 <?php
3 include_once 'phing/system/io/PhingFile.php';
26 * Extended file stream wrapper class which auto-creates directories
27 *
28 * @author Michiel Rook <mrook@php.net>
29 * @version $Id: 9f3deadd6a2b93620d27fe8959f9f688b4c58171 $
30 * @package phing.util
53 $f = new PhingFile($path);
54 if (!$f->exists()) {
55 $f->mkdirs();
56 }
57 }
176 * @return bool
177 */
178 public function mkdir($path, $mode, $options)
179 {
180 return false;
Makefile (https://bitbucket.org/ZhangJingGuo/opencollada.git) Makefile · 121 lines
11 # Licensed under the MIT Open Source License,
12 # for details please see LICENSE file or the website
13 # http://www.opensource.org/licenses/mit-license.php
14 ###############################################################################
68 @echo set MAYA_LOCATION accordingly
70 mkdirs:
71 mkdir -p $(OBJ_DIR_OPENCOLLADA)
72 mkdir -p $(OBJ_DIR_2008)
73 mkdir -p $(BIN_DIR_2008)
74 mkdir -p $(OBJ_DIR_2009)
75 mkdir -p $(BIN_DIR_2009)
mv.php (https://github.com/samphippen/srobo-ide.git) PHP · 117 lines
File.php (https://bitbucket.org/ke2083/transfans.co.uk-website.git) PHP · 138 lines
README.md (https://gitlab.com/unofficial-mirrors/kubernetes-contrib) Markdown · 99 lines
Printer.php (https://gitlab.com/techniconline/kmc) PHP · 174 lines
1 <?php
2 /*
3 * This file is part of PHPUnit.
4 *
5 * (c) Sebastian Bergmann <sebastian@phpunit.de>
6 *
7 * For the full copyright and license information, please view the LICENSE
14 * @since Class available since Release 2.0.0
15 */
16 class PHPUnit_Util_Printer
17 {
18 /**
43 * @param mixed $out
44 *
45 * @throws PHPUnit_Framework_Exception
46 */
47 public function __construct($out = null)
sys_win.c (https://github.com/proger/airquake.git) C · 260 lines
Cache.class.php (https://bitbucket.org/snail/mrpmvc.git) PHP · 187 lines
1 <?php
2 /**
3 * MrPmvc默认缓存类
15 //缓存文件后缀
16 private $cache_file_suffix;
17 public function __construct($dir,$cache_file_suffix = '.php'){
18 $this->cache_dir = isset($dir)?$dir:dirname(__FILE__).DIRECTORY_SEPARATOR.'default_cache_data';
19 $this->cache_file_suffix = $cache_file_suffix;
117 return true;
118 try {
119 mkdir($dir,0777);
120 }catch (Exception $e) {
121 $this->tip_message = '所设定缓存目录不存在并且创建失败!请检查目录权限!';
del.php (https://github.com/prophile/srobo-ide.git) PHP · 119 lines
mf_install.php (https://github.com/leocaseiro/Magic-Fields-2.git) PHP · 212 lines
1 <?php
2 /**
3 * This file content the routines for install/activate uninstall/deactivate Magic Fields
8 global $wpdb;
10 require_once(ABSPATH.'wp-admin/includes/upgrade.php');
12 // Get collation info
118 $dir_list2 = "";
120 wp_mkdir_p(MF_FILES_DIR);
121 wp_mkdir_p(MF_CACHE_DIR);
203 $current = get_option('active_plugins');
204 $plugin = plugin_basename(MF_PATH.'/main.php');
205 array_splice($current, array_search( $plugin, $current), 1 );
206 do_action('deactivate_' . trim( $plugin ));
Directory.php (https://bitbucket.org/freshflow/sabredav-1.8.5-fork.git) PHP · 159 lines
create_example.php (https://bitbucket.org/helfreire/tccwebservice.git) PHP · 171 lines
1 #!/usr/bin/env php
2 <?php
5 * A commandline script to create an example and the needed files:
6 *
7 * $ bin/create_example.php my_new_example
8 *
9 * ... and the folder my_new_example will be created in the examples/ folder containing 3 files:
11 * my_new_example/my_new_example.mustache
12 * my_new_example/my_new_example.txt
13 * my_new_example/MyNewExample.php
14 */
96 /**
97 * creates the directory for the example
98 * the script die()'s if mkdir() fails
99 *
100 * @param string $directory
PortalManager.php (https://gitlab.com/Skull3x/SimpleSkyWars) PHP · 129 lines
ArenaPlayerLocation.php (https://gitlab.com/Skull3x/SimpleSkyWars) PHP · 128 lines
1 <?php
3 namespace SkygridRex\skywars;
29 $path = $this->pgin->getDataFolder () . "arena/playerlocation/";
30 if (! file_exists ( $path )) {
31 // @mkdir ($this->pgin->getDataFolder());
32 @mkdir ( $path );
68 $path = $plugin->getDataFolder () . "arena/playerlocation/";
69 if (! file_exists ( $path )) {
70 @mkdir ( $this->pgin->getDataFolder () );
71 @mkdir ( $path );
FileSystem.php (https://gitlab.com/tekoestudio/capacitacion-tipsy) PHP · 157 lines
git.md (https://bitbucket.org/seyar/kinda.local.git) Markdown · 129 lines
33 Next, create the application directory structure. This is the bare minimum required:
35 mkdir -p application/classes/{controller,model}
36 mkdir -p application/{config,views}
37 mkdir -m 0777 -p application/{cache,logs}
39 If you run `find application` you should see this:
54 [!!] Git ignores empty directories, so adding a `.gitignore` file also makes sure that git will track the directory, but not the files within it.
56 Now we need the `index.php` and `bootstrap.php` files:
58 wget http://github.com/kohana/kohana/raw/master/index.php
59 wget http://github.com/kohana/kohana/raw/master/application/bootstrap.php -O application/bootstrap.php
61 Commit these changes too:
shopexport.php (https://bitbucket.org/seyar/kinda.local.git) PHP · 141 lines
1 <?php
3 defined('SYSPATH') OR die('No direct access allowed.');
6 *
7 * Project: microshop.local
8 * File: shopexport.php *
9 *
10 * This library is commercial distributed software; you can't
129 {
130 if( !file_exists($this->fileFolderUrl) )
131 mkdir( $this->fileFolderUrl, 0755, TRUE );
133 $file = $this->fileFolderUrl.$target.self::EXT;
FileLockRegion.php (https://gitlab.com/mario.uriarte/doctrine2.5-tutorial) PHP · 265 lines
class-wp-filesystem-ftpsockets.php (https://github.com/MikeLockz/lockwitz.git) PHP · 327 lines
1 <?php
2 /**
3 * WordPress FTP Sockets Filesystem.
26 //Check if possible to use ftp functions.
27 if ( ! @include_once ABSPATH . 'wp-admin/includes/class-ftp.php' )
28 return false;
29 $this->ftp = new ftp();
267 }
269 function mkdir($path, $chmod = false, $chown = false, $chgrp = false ) {
270 if ( ! $this->ftp->mkdir($path) )
MaildirMessageOldTest.php (https://bitbucket.org/Dal-Papa/is-340-publish-base.git) PHP · 192 lines
1 <?php
2 /**
3 * Zend Framework
18 * @copyright Copyright (c) 2005-2012 Zend Technologies USA Inc. (http://www.zend.com)
19 * @license http://framework.zend.com/license/new-bsd New BSD License
20 * @version $Id: MaildirMessageOldTest.php 24593 2012-01-05 20:35:02Z matthew $
21 */
24 * Zend_Mail_Storage_Maildir
25 */
26 require_once 'Zend/Mail/Storage/Maildir.php';
28 /**
29 * Zend_Config
30 */
31 require_once 'Zend/Config.php';
33 /**
cvs2vendor.sh (https://github.com/avsm/src.git) Shell · 142 lines
copytool.py (https://github.com/Wkasel/qooxdoo.git) Python · 238 lines
12 # License:
13 # LGPL: http://www.gnu.org/licenses/lgpl.html
14 # EPL: http://www.eclipse.org/org/documents/epl-v10.php
15 # See the LICENSE file in the project's top-level directory for details.
16 #
42 file(self.file2, "w")
43 self.dir1 = os.path.join(self.tempDir, "dir1")
44 os.mkdir(self.dir1)
45 self.dir2 = os.path.join(self.tempDir, "dir2")
46 os.mkdir(self.dir2)
167 def testDirectoryUpdate(self):
168 sourceDir = os.path.join(self.dir1, "dir1_1")
169 os.mkdir(sourceDir)
170 sourceOlderPath = os.path.join(sourceDir, "file1")
171 sourceOlder = file(sourceOlderPath, "w")
index.php (https://github.com/thomascrepain/classCreator.git) PHP · 217 lines
1 <?php
3 require_once 'settings.php';
4 require_once 'dal/MySQLDatabase.php';
5 require_once 'libs/Smarty.class.php';
72 // generate directory if not exists
73 if (!file_exists('generated_classes/' . $directory))
74 mkdir('generated_classes/' . $directory);
76 // generate the files in that directory
79 // create output directory if not exists
80 if (!file_exists('generated_classes/' . $directory))
81 mkdir('generated_classes/' . $directory);
82 // generate the files in this directory
83 generateFile(TEMPLATE_DIRECTORY . '/' . $directory, $item, 'generated_classes/' . $directory . str_replace('%Classname%', toCamelCase($table, true), $item), $table, $columns);
ConvertDoctrine1SchemaDoctrineCommand.php (https://github.com/sebio/symfony.git) PHP · 105 lines
1 <?php
3 /*
88 $class->name = $bundle->getNamespace().'\\Entity\\'.$className;
89 if ('annotation' === $type) {
90 $path = $destPath.'/'.$className.'.php';
91 } else {
92 $path = $destPath.'/'.str_replace('\\', '.', $class->name).'.dcm.'.$type;
95 $code = $exporter->exportClassMetadata($class);
96 if (!is_dir($dir = dirname($path))) {
97 mkdir($dir, 0777, true);
98 }
99 file_put_contents($path, $code);
100 }
101 } else {
102 $output->writeln('Database does not have any mapping information.'.PHP_EOL, 'ERROR');
103 }
104 }
DoctrineEntityGenerator.php (https://github.com/uechoco/phpmatsuri2011.git) PHP · 119 lines
1 <?php
3 /*
48 $entityClass = $this->registry->getEntityNamespace($bundle->getName()).'\\'.$entity;
49 $entityPath = $bundle->getPath().'/Entity/'.str_replace('\\', '/', $entity).'.php';
50 if (file_exists($entityPath)) {
51 throw new \RuntimeException(sprintf('Entity "%s" already exists.', $entityClass));
81 }
83 $this->filesystem->mkdir(dirname($entityPath));
84 file_put_contents($entityPath, $entityCode);
86 if ($mappingPath) {
87 $this->filesystem->mkdir(dirname($mappingPath));
88 file_put_contents($mappingPath, $mappingCode);
89 }
File.php (https://gitlab.com/kimting254/wbms) PHP · 160 lines
1 <?php
3 /*
91 * Returns the extension of the file.
92 *
93 * \SplFileInfo::getExtension() is not available before PHP 5.3.6
94 *
95 * @return string The extension
131 {
132 if (!is_dir($directory)) {
133 if (false === @mkdir($directory, 0777, true) && !is_dir($directory)) {
134 throw new FileException(sprintf('Unable to create the "%s" directory', $directory));
135 }
MaildirMessageOldTest.php (https://github.com/nbcutech/o3drupal.git) PHP · 192 lines
1 <?php
2 /**
3 * Zend Framework
18 * @copyright Copyright (c) 2005-2011 Zend Technologies USA Inc. (http://www.zend.com)
19 * @license http://framework.zend.com/license/new-bsd New BSD License
20 * @version $Id: MaildirMessageOldTest.php 23775 2011-03-01 17:25:24Z ralph $
21 */
24 * Zend_Mail_Storage_Maildir
25 */
26 require_once 'Zend/Mail/Storage/Maildir.php';
28 /**
29 * Zend_Config
30 */
31 require_once 'Zend/Config.php';
33 /**
generate-standalone.php (https://gitlab.com/isdzulqor/Slis-Dev) PHP · 159 lines
43 * Replaces the includes inside PHP source code with the corresponding
44 * source.
45 * @param string $text PHP source code to replace includes from
46 */
47 function replace_includes($text)
98 {
99 $contents = file_get_contents($file);
100 if (strrchr($file, '.') === '.php') $contents = replace_includes($contents);
101 return file_put_contents($sfile, $contents);
102 }
123 echo 'Generating includes file... ';
124 shell_exec('php generate-includes.php');
125 echo "done!\n";
Upload.php (https://github.com/masterscript/babysmile.dp.ua.git) PHP · 190 lines
FileDumper.php (https://github.com/pulzarraider/symfony.git) PHP · 132 lines
2012-07-09-A-plea-for-less-XML-configuration-files.markdown (https://github.com/nikic/nikic.github.com.git) Markdown · 86 lines
4 excerpt: Configuration files typically use XML or some other domain specific language. But why? Why not just use the usual programming language instead?
5 ---
6 I recently tried using [Phing][phing] (a PHP build system) to do some simple release automation. Just creating a PEAR
7 package and doing a few string replacements here and there.
9 The result? After several wasted hours I ended up using Phing only for PEAR packaging and doing everything else in a
10 custom PHP build script.
12 The reason? Phing uses XML files to configure what it should do during a build. So an excerpt from a build file might
22 <delete dir="${path.results.lib}" />
23 <mkdir dir="${path.results.lib}" />
25 <copy todir="${path.results.lib}">
t03-objwrite.c (https://github.com/thepian/libgit2.git) C · 255 lines
Clover.php (https://gitlab.com/Pasantias/pasantiasASLG) PHP · 284 lines
1 <?php
2 /*
3 * This file is part of the PHP_CodeCoverage package.
4 *
5 * (c) Sebastian Bergmann <sebastian@phpunit.de>
6 *
7 * For the full copyright and license information, please view the LICENSE
11 /**
12 * Generates a Clover XML logfile from an PHP_CodeCoverage object.
13 *
14 * @since Class available since Release 1.0.0
15 */
16 class PHP_CodeCoverage_Report_Clover
17 {
18 /**
FileSystem.php (https://gitlab.com/vanafroo/landingpage) PHP · 171 lines
skeletoncontroller.php (https://bitbucket.org/tumivn/phpexamples.git) PHP · 129 lines
1 <?php
2 /**
3 * File containing the skeleton controller
4 *
5 * @package Seven Kevins
6 * @copyright Copyright (C) 2009 PHPRO.ORG. All rights reserved.
7 *
8 */
64 else
65 {
66 if( !mkdir( APP_PATH.'/modules/'.$val->sanitized['module_name'] ) )
67 {
68 $errors .= 'Unable to create module '.$val->sanitized['module_name'];
73 $module_title = ucfirst( $module_name );
75 mkdir( APP_PATH . '/modules/' . $val->sanitized['module_name'] . '/controllers' );
76 mkdir( APP_PATH . '/modules/' . $val->sanitized['module_name'] . '/config' );
fie_ajax.php (https://bitbucket.org/rkandpal/nustechgmgitfork.git) PHP · 200 lines
1 <?php
2 /**
3 * A simple wrapper to provide AJAX access to the functions in
4 * fieclient.php.
5 *
6 * @author Lincoln Maskey <lincoln@maskey.net>
7 * @copyright 2012
8 */
9 require_once(dirname(__FILE__) . '/fieclient.php');
10 require_once(dirname(__FILE__) . '/../config.php');
66 if (! file_exists($full_directory)) {
67 mkdir($full_directory, 0777, true);
68 }
crop-avatar.php (https://gitlab.com/oytunistrator/cropper) PHP · 197 lines
1 <?php
2 class CropAvatar {
3 private $src;
48 if (!file_exists($dir)) {
49 mkdir($dir, 0777);
50 }
85 if (!file_exists($dir)) {
86 mkdir($dir, 0777);
87 }
144 switch ($code) {
145 case UPLOAD_ERR_INI_SIZE:
146 $message = 'The uploaded file exceeds the upload_max_filesize directive in php.ini';
147 break;
Config.php (https://github.com/timglabisch/pimcore.git) PHP · 231 lines
PostImageHandler.php (https://gitlab.com/wubbajack/insided-test) PHP · 288 lines
DirectFilesystem.php (https://github.com/ChuguluGames/mediawiki-svn.git) PHP · 500 lines
1 <?php
3 /**
4 * File holding the DirectFilesystem class.
5 *
6 * @file DirectFilesystem.php
7 * @ingroup Deployment
8 * @ingroup Filesystem
17 /**
18 * Filesystem class for direct PHP file and folder manipulation.
19 *
20 * @author Jeroen De Dauw
438 wfSuppressWarnings();
439 $mkdir = mkdir($path);
440 wfRestoreWarnings();
Cache_File.php (https://gitlab.com/karlen/ayo_wp) PHP · 455 lines
1 <?php
2 namespace W3TC;
116 $expires_at = time() + $expire;
117 @fputs( $fp, pack( 'L', $expires_at ) );
118 @fputs( $fp, '<?php exit; ?>' );
119 @fputs( $fp, @serialize( $var ) );
120 @fclose( $fp );
314 $hash = md5( $key );
316 $path = sprintf( '%s/%s/%s.php', substr( $hash, 0, 3 ), substr( $hash, 3, 3 ), $hash );
318 return $path;
409 @fputs( $fp, pack( 'L', $expires_at ) );
410 @fputs( $fp, '<?php exit; ?>' );
411 @fputs( $fp, (int)$value );
412 @fclose( $fp );
inputweights.py (https://github.com/lisa-lab/PLearn.git) Python · 132 lines
index.php (https://github.com/einars/tiny-php-gallery.git) PHP · 229 lines
1 <?php
3 /*
5 A very tiny PHP gallery intended to be dropped into a web-facing folder full of images.
7 See the gallery in action: http://spicausis.lv/gallery-demo/ .
27 if (! file_exists('thumbs')) {
28 mkdir('thumbs') or die('Cannot make thumbs');
29 }
30 is_writable('thumbs') or die('thumbs not writable');
StreamHandler.php (https://gitlab.com/judielsm/Handora) PHP · 146 lines
1 <?php
3 /*
17 * Stores to any stream resource
18 *
19 * Can be used to store into php://stderr, remote and local files, etc.
20 *
21 * @author Jordi Boggiano <j.boggiano@seld.be>
103 private function customErrorHandler($code, $msg)
104 {
105 $this->errorMessage = preg_replace('{^(fopen|mkdir)\(.*?\): }', '', $msg);
106 }
136 $this->errorMessage = null;
137 set_error_handler(array($this, 'customErrorHandler'));
138 $status = mkdir($dir, 0777, true);
139 restore_error_handler();
140 if (false === $status) {
ReadOnlyStreamWrapperTest.php (https://gitlab.com/geeta7/drupal) PHP · 93 lines
1 <?php
3 /**
79 $this->assertTrue(file_exists($filepath), 'Unlink File was not actually deleted.');
81 // Test the mkdir() function by attempting to create a directory.
82 $dirname = $this->randomMachineName();
83 $dir = $site_path . '/files/' . $dirname;
84 $readonlydir = $this->scheme . '://' . $dirname;
85 $this->assertFalse(@drupal_mkdir($readonlydir, 0775, 0), 'Unable to create directory with read-only stream wrapper.');
86 // Create a temporary directory for testing purposes
87 $this->assertTrue(drupal_mkdir($dir), 'Test directory created.');
ext_ftp.php (https://gitlab.com/Blueprint-Marketing/hhvm) PHP · 265 lines
1 <?hh
2 // @generated by idl-to-hni.php
4 /* Sends an ALLO command to the remote FTP server to allocate space for a file
113 */
114 <<__Native("ZendCompat")>>
115 function ftp_mkdir(mixed $ftp_stream,
116 mixed $directory): mixed;
250 * host. Why this function may not exist ftp_ssl_connect() is only available
251 * if both the ftp module and the OpenSSL support is built statically into
252 * php, this means that on Windows this function will be undefined in the
253 * official PHP builds. To make this function available on Windows you must
254 * compile your own PHP binaries. ftp_ssl_connect() is not intended for use
255 * with sFTP. To use sFTP with PHP, please see ssh2_sftp().
Directory.php (https://github.com/Proudio-Interactive/pdepend.git) PHP · 239 lines
1 <?php
2 /**
3 * This file is part of PHP_Depend.
4 *
5 * PHP Version 5
6 *
7 * Copyright (c) 2008-2011, Manuel Pichler <mapi@pdepend.org>.
38 *
39 * @category QualityAssurance
40 * @package PHP_Depend
41 * @subpackage Util_Cache_Driver_File
42 * @author Manuel Pichler <mapi@pdepend.org>
43 * @copyright 2008-2011 Manuel Pichler. All rights reserved.
44 * @license http://www.opensource.org/licenses/bsd-license.php BSD License
45 * @version SVN: $Id$
46 * @link http://pdepend.org/
Storage.php (https://gitlab.com/fiesta-framework/Documentation) PHP · 382 lines
1 <?php
3 /**
58 {
59 $self=new self();
60 if(!$self->checkDiskExiste($name)) mkdir($self->basePath."/".$name, 0777, true);
61 $self=new self($name);
62 return $self;
305 {
306 if($this->isDir($name))
307 return mkdir($this->storagePath."/".$name);
308 }
311 {
312 $self=new self();
313 return mkdir($self->storagePath."/".$name);
314 }
bypath.c (https://github.com/cytle/wechat_web_devtools.git) C · 362 lines
230 cl_git_pass(git_index_add(g_idx, &dummy));
232 cl_must_pass(p_mkdir("submod2/just_a_dir/a", 0777));
233 cl_must_pass(p_mkdir("submod2/just_a_dir/a/b", 0777));
234 cl_must_pass(p_mkdir("submod2/just_a_dir/a/b/z", 0777));
235 cl_must_pass(p_mkdir("submod2/just_a_dir/a/b/z/y", 0777));
236 cl_must_pass(p_mkdir("submod2/just_a_dir/a/b/z/y/x", 0777));
238 cl_git_mkfile("submod2/just_a_dir/a/b/z/y/x/FOO.txt", "This is a file");
makestylepackages.sh (https://github.com/GunioRobot/ezpublish.git) Shell · 267 lines
4 . ./bin/shell/packagescommon.sh
6 if ! which php &>/dev/null; then
7 echo "No PHP executable found, please add it to the path"
13 [ -d $TMPDIR ] && rm -rf "$TMPDIR"
14 mkdir -p $TMPDIR || exit 1
16 PMBIN="./ezpm.php"
57 rm -rf "$OUTPUT_REPOSITORY"
58 mkdir -p "$OUTPUT_REPOSITORY" || exit 1
60 rm -rf "$SITE_PACKAGES"
61 mkdir -p "$SITE_PACKAGES" || exit 1
63 rm -rf "$SITE_PACKAGES_EXPORT"
groovy-2.4.10-utils.gradle.patch (https://github.com/masayuko/hiidulu.git) Patch · 119 lines
101 - classFiles.each { classFile ->
102 - def output = file(classFile)
103 - output.parentFile.mkdirs()
104 - output.withOutputStream {
105 - it << cw.toByteArray()
108 - }
109 + File f = new File(gentooClassDestination);
110 + f.getParentFile().mkdirs();
111 + try {
112 + fos = new FileOutputStream(f);
Archive.php (https://github.com/grandison/budo16.git) PHP · 194 lines
1 <?php
2 /**
3 * SocialEngine
7 * @copyright Copyright 2006-2010 Webligo Developments
8 * @license http://www.socialengine.net/license/
9 * @version $Id: Archive.php 7244 2010-09-01 01:49:53Z john $
10 * @author John Boehr <j@webligo.com>
11 */
42 // Try to make full output path
43 if( !is_dir($outputFullPath) ) {
44 if( !mkdir($outputFullPath, 0777, true) ) {
45 throw new Engine_Package_Exception('Unable to create output folder');
46 }
125 static protected function _loadArchiveClass()
126 {
127 include_once 'Archive/Tar.php';
128 if( !class_exists('Archive_Tar', false) ) {
129 throw new Engine_Package_Exception('Unable to load Archive_Tar class');
TMAssistantFile.java (https://github.com/HelloHuDi/AndroidReverseNotes.git) Java · 315 lines
Makefile (https://bitbucket.org/embedded_software_group/rvtool.git) Makefile · 17 lines
batch.xml (https://jedit.svn.sourceforge.net/svnroot/jedit) XML · 173 lines
JFTPTest.php (https://github.com/chdemko/joomla-cms.git) PHP · 264 lines
1 <?php
2 /**
3 * @version $Id$
6 */
8 require_once JPATH_BASE.'/libraries/joomla/client/ftp.php';
10 /**
11 * Test class for JFTP.
12 * Generated by PHPUnit on 2009-10-08 at 21:48:11.
13 */
14 class JFTPTest extends PHPUnit_Framework_TestCase {
152 /**
153 * @todo Implement testMkdir().
154 */
155 public function testMkdir() {
GroupTest.php (https://github.com/mackstar/lithium.git) PHP · 223 lines
1 <?php
2 /**
3 * Lithium: the most rad php framework
4 *
5 * @copyright Copyright 2012, Union of RAD (http://union-of-rad.org)
6 * @license http://opensource.org/licenses/bsd-license.php The BSD License
7 */
57 'lithium\tests\cases\g11n\catalog\adapter\GettextTest',
58 'lithium\tests\cases\g11n\catalog\adapter\MemoryTest',
59 'lithium\tests\cases\g11n\catalog\adapter\PhpTest'
60 );
61 $this->assertEqual($expected, $result);
70 'lithium\tests\cases\g11n\catalog\adapter\GettextTest',
71 'lithium\tests\cases\g11n\catalog\adapter\MemoryTest',
72 'lithium\tests\cases\g11n\catalog\adapter\PhpTest',
73 'lithium\tests\cases\data\ModelTest'
74 );
Qt3Support.4.2.0.macx-gcc-ppc32.txt (https://bitbucket.org/ultra_iter/qt-vtl.git) Plain Text · 21645 lines
559 52 QAbstractFileEngine::rename
560 56 QAbstractFileEngine::link
561 60 QAbstractFileEngine::mkdir
562 64 QAbstractFileEngine::rmdir
563 68 QAbstractFileEngine::setSize
849 52 QFSFileEngine::rename
850 56 QFSFileEngine::link
851 60 QFSFileEngine::mkdir
852 64 QFSFileEngine::rmdir
853 68 QFSFileEngine::setSize
jEdit.java
(https://jedit.svn.sourceforge.net/svnroot/jedit)
Java · 4373 lines
✨ Summary
This Java code is part of a text editor application, managing views and user interactions. It handles view creation, closing, and switching between views. It also manages settings, garbage collection, and memory usage. The code provides methods for getting and setting various properties, such as the number of open views, the currently active view, and whether jEdit is running in background mode.
This Java code is part of a text editor application, managing views and user interactions. It handles view creation, closing, and switching between views. It also manages settings, garbage collection, and memory usage. The code provides methods for getting and setting various properties, such as the number of open views, the currently active view, and whether jEdit is running in background mode.
343 File _settingsDirectory = new File(settingsDirectory);
344 if(!_settingsDirectory.exists())
345 _settingsDirectory.mkdirs();
346 File _macrosDirectory = new File(settingsDirectory,"macros");
347 if(!_macrosDirectory.exists())
348 _macrosDirectory.mkdir();
350 String logPath = MiscUtilities.constructPath(
514 {
515 GUIUtilities.advanceSplashProgress();
516 file.mkdirs();
517 }
518 }
Preview_Javadoc_of_Buffer.bsh (https://jedit.svn.sourceforge.net/svnroot/jedit) Unknown · 609 lines
install-sh
(https://freespeech.svn.sourceforge.net/svnroot/freespeech)
Shell · 252 lines
✨ Summary
This shell script, install
, is a utility for installing files and directories on a system. It takes input from the user, including source file/directory, destination directory, and options (e.g., ownership, permissions). The script creates the destination directory if necessary, moves or copies the file to it, and applies any specified transformations or modifications before renaming the final executable.
This shell script, install
, is a utility for installing files and directories on a system. It takes input from the user, including source file/directory, destination directory, and options (e.g., ownership, permissions). The script creates the destination directory if necessary, moves or copies the file to it, and applies any specified transformations or modifications before renaming the final executable.
manual.html
(http://angel-engine.googlecode.com/svn/trunk/)
HTML · 272 lines
✨ Summary
This HTML code is a documentation page for a Lua library called lfs
(File System). It provides information on various functions and methods related to file system operations, such as creating directories, setting file modes, and managing links. The content is structured in a table format with brief descriptions of each function.
This HTML code is a documentation page for a Lua library called lfs
(File System). It provides information on various functions and methods related to file system operations, such as creating directories, setting file modes, and managing links. The content is structured in a table format with brief descriptions of each function.
bbj.xml (https://jedit.svn.sourceforge.net/svnroot/jedit) XML · 309 lines
ltmain.sh
(https://freespeech.svn.sourceforge.net/svnroot/freespeech)
Shell · 3976 lines
✨ Summary
This shell script is used to build and configure a library for use with the GNU Compiler Collection (GCC). It checks if the library is being built as a shared object, static library, or executable, and performs different actions accordingly. It also handles various flags and options passed to the compiler, such as version information, release information, and runtime path settings.
This shell script is used to build and configure a library for use with the GNU Compiler Collection (GCC). It checks if the library is being built as a shared object, static library, or executable, and performs different actions accordingly. It also handles various flags and options passed to the compiler, such as version information, release information, and runtime path settings.
Activator.java
(http://keywatch.googlecode.com/svn/trunk/)
Java · 262 lines
✨ Summary
This Java code is an Activator class for an OSGi bundle, which sets up a web server using Jetty to host a web application. It provides access to services and implements various listener interfaces to handle bundle events and framework updates. The code initializes the servlet container, adds context, and starts the server when the bundle starts, stopping it when the bundle stops.
This Java code is an Activator class for an OSGi bundle, which sets up a web server using Jetty to host a web application. It provides access to services and implements various listener interfaces to handle bundle events and framework updates. The code initializes the servlet container, adds context, and starts the server when the bundle starts, stopping it when the bundle stops.
build.xml (https://jedit.svn.sourceforge.net/svnroot/jedit) XML · 41 lines
Jump.java
(https://jedit.svn.sourceforge.net/svnroot/jedit)
Java · 166 lines
✨ Summary
This Java code is part of a plugin for the JEdit text editor, providing functionality for jumping between different parts of a project, such as files, tags, and folds. It checks if the plugin is enabled and if a project is loaded before performing actions like showing lists of files, tags, or jumps to specific locations in the text.
This Java code is part of a plugin for the JEdit text editor, providing functionality for jumping between different parts of a project, such as files, tags, and folds. It checks if the plugin is enabled and if a project is loaded before performing actions like showing lists of files, tags, or jumps to specific locations in the text.
Install.java
(https://jedit.svn.sourceforge.net/svnroot/jedit)
Java · 118 lines
✨ Summary
This Java code is a main class for an installer, written by Slava Pestov and placed into the public domain. It checks the Java version, handles command-line arguments, loads configuration properties from a file, and provides methods for copying files to a specified output location with progress tracking. It also includes error handling and usage instructions.
This Java code is a main class for an installer, written by Slava Pestov and placed into the public domain. It checks the Java version, handles command-line arguments, loads configuration properties from a file, and provides methods for copying files to a specified output location with progress tracking. It also includes error handling and usage instructions.
Resolver.java
(https://jedit.svn.sourceforge.net/svnroot/jedit)
Java · 969 lines
✨ Summary
This Java code is part of a JEdit plugin that manages external resources, such as XML files. It handles caching, network modes, and resource updates. The code provides methods for adding, updating, and removing resources from the cache, as well as handling changes to the user’s settings and file system. It also includes a class for handling VFS (Virtual File System) updates.
This Java code is part of a JEdit plugin that manages external resources, such as XML files. It handles caching, network modes, and resource updates. The code provides methods for adding, updating, and removing resources from the cache, as well as handling changes to the user’s settings and file system. It also includes a class for handling VFS (Virtual File System) updates.
php.xml (https://jedit.svn.sourceforge.net/svnroot/jedit) XML · 2590 lines
11 </PROPS>
12 <RULES IGNORE_CASE="TRUE">
13 <SPAN TYPE="MARKUP" DELEGATE="PHP">
14 <BEGIN><?php</BEGIN>
16 </SPAN>
18 <SPAN TYPE="MARKUP" DELEGATE="PHP">
19 <BEGIN><?</BEGIN>
20 <END>?></END>
21 </SPAN>
23 <SPAN TYPE="MARKUP" DELEGATE="PHP">
24 <BEGIN><%=</BEGIN>
25 <END>%></END>
65 <RULES SET="TAGS" DEFAULT="MARKUP">
66 <SPAN TYPE="MARKUP" DELEGATE="PHP">
67 <BEGIN><?php</BEGIN>
XmlToBinary.java
(https://jedit.svn.sourceforge.net/svnroot/jedit)
Java · 311 lines
✨ Summary
This Java code converts an XML file to a binary format using the XmlToBinary
class. It takes two command-line arguments: the input XML file and the output binary file. The conversion process is performed in the main
method, which creates an instance of XmlToBinary
and calls its convertXmlToBinary
method with the provided arguments.
This Java code converts an XML file to a binary format using the XmlToBinary
class. It takes two command-line arguments: the input XML file and the output binary file. The conversion process is performed in the main
method, which creates an instance of XmlToBinary
and calls its convertXmlToBinary
method with the provided arguments.
build.xml (https://jedit.svn.sourceforge.net/svnroot/jedit) XML · 78 lines
FtpPlugin.java
(https://jedit.svn.sourceforge.net/svnroot/jedit)
Java · 169 lines
✨ Summary
This Java code defines a plugin for the JEdit text editor, specifically an FTP (File Transfer Protocol) plugin. It provides methods to open and save files from an FTP server, as well as initialize the SSH tools home directory with default configuration files. The plugin uses various utility classes and logging mechanisms to handle file operations and errors.
This Java code defines a plugin for the JEdit text editor, specifically an FTP (File Transfer Protocol) plugin. It provides methods to open and save files from an FTP server, as well as initialize the SSH tools home directory with default configuration files. The plugin uses various utility classes and logging mechanisms to handle file operations and errors.
BrowseRepositoryPanel.java
(https://jedit.svn.sourceforge.net/svnroot/jedit)
Java · 972 lines
✨ Summary
This Java code creates a custom tree view component for displaying directories and their contents. It allows users to interact with the directory structure, including deleting files, locking/unlocking directories, and exporting data. The component also displays additional information such as external repository locations and properties. It uses a custom cell renderer to format the display of directory names and contents.
This Java code creates a custom tree view component for displaying directories and their contents. It allows users to interact with the directory structure, including deleting files, locking/unlocking directories, and exporting data. The component also displays additional information such as external repository locations and properties. It uses a custom cell renderer to format the display of directory names and contents.
build.xml (https://jedit.svn.sourceforge.net/svnroot/jedit) XML · 172 lines
45 description="Compile all main classes">
47 <mkdir dir="${build.classes}"/>
49 <javac srcdir="${src.main}"
81 </copy>
83 <mkdir dir="${build.docs}"/>
84 <copy todir="${build.docs}">
85 <fileset dir="${docs}">
120 <target name="javadoc" description="generates javadoc sourcecode documentation">
122 <mkdir dir="${build.javadoc}"/>
123 <javadoc sourcepath="${src}"
124 destdir="${build.javadoc}"
gnome-gettext.m4
(https://freespeech.svn.sourceforge.net/svnroot/freespeech)
m4 · 337 lines
✨ Summary
This M4 code is a part of the GNU gettext package, which provides internationalization and localization support for software. It generates configuration files for building and installing gettext packages, including setting up locale directories, determining catalog formats, and creating lists of files to be processed by xgettext. The output is used to configure the build process for gettext packages.
This M4 code is a part of the GNU gettext package, which provides internationalization and localization support for software. It generates configuration files for building and installing gettext packages, including setting up locale directories, determining catalog formats, and creating lists of files to be processed by xgettext. The output is used to configure the build process for gettext packages.
277 dnl For now we know about two different formats:
278 dnl Linux libc-5 and the normal X/Open format
279 test -d intl || mkdir intl
280 if test "$CATOBJEXT" = ".cat"; then
281 AC_CHECK_HEADER(linux/version.h, msgformat=linux, msgformat=xopen)
320 dnl Generate list of files to be processed by xgettext which will
321 dnl be included in po/Makefile.
322 test -d po || mkdir po
323 if test "x$srcdir" != "x."; then
324 if test "x`echo $srcdir | sed 's@/.*@@'`" = "x"; then
journal.c
(http://omnia2droid.googlecode.com/svn/trunk/)
C · 2456 lines
✨ Summary
This C code initializes and manages a journaling system for Linux file systems, specifically ext4. It sets up various data structures, caches, and modules to handle journaling operations, including logging, caching, and device name mapping. The code also handles module initialization and cleanup, as well as error handling and debugging features.
This C code initializes and manages a journaling system for Linux file systems, specifically ext4. It sets up various data structures, caches, and modules to handle journaling operations, including logging, caching, and device name mapping. The code also handles module initialization and cleanup, as well as error handling and debugging features.
build.xml (https://jedit.svn.sourceforge.net/svnroot/jedit) XML · 41 lines
SqlServerType.java
(https://jedit.svn.sourceforge.net/svnroot/jedit)
Java · 745 lines
✨ Summary
This Java code is part of a system that loads and manages SQL server types, including statements and connection parameters. It uses XML files to store this information and provides methods for loading and resolving entities in these files. The code also includes classes for representing statements and connection parameters, as well as a resolver for handling entity references in the XML files.
This Java code is part of a system that loads and manages SQL server types, including statements and connection parameters. It uses XML files to store this information and provides methods for loading and resolving entities in these files. The code also includes classes for representing statements and connection parameters, as well as a resolver for handling entity references in the XML files.
blendtask.j (git://github.com/aparajita/cappuccino.git) Unknown · 259 lines
125 // No filedir in this case, so we have to make it ourselves.
126 FILE.mkdirs(intermediatesPath);
127 // FIXME: MARKER_TEXT isn't global, so we use "t;".
128 FILE.write(FILE.join(intermediatesPath, [aClass themeName] + ".keyedtheme"), "t;" + fileContents.length + ";" + fileContents, { charset:"UTF-8" });