Name of the project
351358
def create_new(projectname):
    """"""
    git_url = "https://github.com/moluwole/Bast_skeleton"
    path = os.path.abspath('.') + "/" + projectname
    if not os.path.exists(path):
        os.makedirs(path)

    click.echo(Fore.GREEN + '    ___  ___   __________')
    click.echo(Fore.GREEN + '  / _ )/ _ | / __/_  __/')
    click.echo(Fore.GREEN + ' / _  / __ |_\ \  / /')
    click.echo(Fore.GREEN + '/____/_/ |_/___/ /_/')

    click.echo(Fore.GREEN + "Creating Project at %s.... " % path)
    click.echo(Fore.GREEN + "Pulling Project Skeleton from Repo")
    try:
        Repo.clone_from(git_url, path)

        click.echo(Fore.GREEN + "Setting up project")

        shutil.rmtree(path + "/.git")

        if not os.path.exists('/.env'):
            shutil.copy(path + '/.env.example', path + '/.env')

        env_file = path + "/.env"
        if not os.path.isfile(env_file):
            shutil.copy('.env.example', '.env')
        call(['panther', 'generate:key', path])

        click.echo(Fore.GREEN + "New Bast Project created at  %s " % path)
    except Exception as e:
        click.echo(Fore.RED + "An error occurred creating a new project. Try Again.\n Reason: {}".format(e))
94123
def _update_project(config, task_presenter, results,
                    long_description, tutorial):
    """"""
    try:
        # Get project
        project = find_project_by_short_name(config.project['short_name'],
                                             config.pbclient,
                                             config.all)
        # Update attributes
        project.name = config.project['name']
        project.short_name = config.project['short_name']
        project.description = config.project['description']
        # Update long_description
        with open(long_description, 'r') as f:
            project.long_description = f.read()
        # Update task presenter
        with open(task_presenter, 'r') as f:
            project.info['task_presenter'] = f.read()
        _update_task_presenter_bundle_js(project)
        # Update results
        with open(results, 'r') as f:
            project.info['results'] = f.read()
        # Update tutorial
        with open(tutorial, 'r') as f:
            project.info['tutorial'] = f.read()
        response = config.pbclient.update_project(project)
        check_api_error(response)
        return ("Project %s updated!" % config.project['short_name'])
    except exceptions.ConnectionError:
        return ("Connection Error! The server %s is not responding" % config.server)
    except ProjectNotFound:
        return ("Project not found! The project: %s is missing." \
                " Use the flag --all=1 to search in all the server " \
                % config.project['short_name'])
    except TaskNotFound:
        raise
392560
def by_name(self, name, archived=False, limit=None, page=None):
        
        # this only works with the exact name
        return super(Projects, self).by_name(name, archived=archived,
                                             limit=limit, page=page)
987692
def get_project(self, name):
        
        uri = '{base}/{project}'.format(base=self.BASE_URI, project=name)
        resp = self._client.get(uri, model=models.Project)

        return resp
263565
def rename(self, name, **kwargs):
        

        return self._rename(self._dxid, {"project": self._proj,
                                         "name": name}, **kwargs)
872880
def full_name(self):
        """"""
        if self._full_name is None:
            self._full_name = 'projects/{project}/taskqueues/{taskqueue}'.format(project=self.project,
                                                                                 taskqueue=self.id)
        return self._full_name
416046
def create_project(self, name=None, project_id=None, path=None):
        

        if project_id is not None and project_id in self._projects:
            return self._projects[project_id]
        project = Project(name=name, project_id=project_id, path=path)
        self._check_available_disk_space(project)
        self._projects[project.id] = project
        return project
439289
def create_project(project, opts = {})
      data, _status_code, _headers = create_project_with_http_info(project, opts)
      return data
    end
521536
def egg_name(self):
        """"""
        filename = "%s-%s-py%s" % (
            to_filename(self.project_name), to_filename(self.version),
            self.py_version or PY_MAJOR
        )

        if self.platform:
            filename += '-' + self.platform
        return filename
1366002
def _update_projects(self):
        ''''''
        now = time.time()
        if (
                not self._force_update_project
                and self._last_update_project + self.UPDATE_PROJECT_INTERVAL > now
        ):
            return
        for project in self.projectdb.check_update(self._last_update_project):
            self._update_project(project)
            logger.debug("project: %s updated.", project['name'])
        self._force_update_project = False
        self._last_update_project = now
1279831
def title(self) -> typing.Union[None, str]:
        """"""
        return self._project.title if self._project else None
124679
def get_project(name)
      params = {
        'command' => 'listProjects',
	'listall' => true
      }

      json = send_request(params)
      projects = json['project']
      return nil unless projects

      projects.each { |n|
        if name.is_uuid? then
          return n if n['id'] == name
        else
          return n if n['name'] == name
        end
      }
      nil
    end
991837
def create_project(self, data):
        """"""
        # http://teampasswordmanager.com/docs/api-projects/#create_project
        log.info('Create project: %s' % data)
        NewID = self.post('projects.json', data).get('id')
        log.info('Project has been created with ID %s' % NewID)
        return NewID
721126
function getOldProjectName(projectDir) {
  var files = [];
  try {
    files = fs.readdirSync(projectDir);
  } catch (err) {
    return '';
  }

  var projectFile = '';
  files.forEach(function(fileName) {
    if (path.extname(fileName) === '.xcodeproj') {
      projectFile = path.basename(fileName, '.xcodeproj');
    }
  });

  return projectFile;
}
655543
def _project_name(self):
        
        name = getattr(self._req.req, 'project_name', '')
        if name:
            return name
        name = getattr(self._req.req, 'name', '')
        if name:
            return safe_name(name)
        raise ValueError('Requirement has no project_name.')
1373979
public Request request(String name, Project project) {
        return request(name, project, null);
    }
63469
def generate(self, project):
		
		for assignment in self.s2n_mapping:
			if assignment["ipprefix"] == project:
				self._name = assignment["package"]
				return self

		#
		# github.com -> github
		# code.google.com/p/ -> googlecode
		# golang.org/x/ -> golangorg
		# gopkg.in/check.v1 -> gopkg-check
		# camlistore.org
		#

		name = project
		if name.startswith("github.com"):
			name = re.sub(r"^github\.com", "github", name)

		if name.startswith("gopkg.in"):
			name = re.sub(r"gopkg\.in", "gopkg", name)
			# any version marks?
			name = re.sub(r"\.v\d", "", name)
			name = re.sub(r"/v\d/", "/", name)

		if name.startswith("code.google.com/p"):
			name = re.sub(r"^code\.google\.com/p", "googlecode", name)

		if name.startswith("golang.org/x"):
			name = re.sub(r"^golang\.org/x", "golangorg", name)

		if name.startswith("google.golang.org"):
			name = re.sub(r"^google\.golang\.org", "googlegolangorg", name)

		if name.startswith("bitbucket.org"):
			name = re.sub(r"^bitbucket\.org", "bitbucket", name)

		if name.startswith("k8s.io"):
			name = re.sub(r"^k8s\.io", "k8s", name)

		if name.endswith(".org"):
			name = re.sub(r"\.org$", "", name)

		name = name.replace("/", "-")

		self._name = "golang-%s" % name

		return self