U Exam Questions 1 Flashcards
Which permission levels exist for a GitHub personal account repository?
a. the repository owner, collaborators and team maintainers
b. the repository owner and moderator
c. the repository owner, collaborators and viewers
b. the repository owner and collaborators
Overall explanation
A repository owned by a personal account has two permission levels: the repository owner and collaborators.
Wrong Answers
There is not a viewer permission level for personal account repositories on GitHub. Collaborators can’t have read-only access to repositories owned by a personal account.
There is not a team maintainer permission level for personal account repositories on GitHub. Team maintainers are only available for organization accounts.
There is not a moderator permission level for personal account repositories on GitHub. The Moderator role is only available for organization accounts.
Who can use the Insights feature for Projects?
a. only users with admin access to a project
b. users with write or admin access to a project
c. users with GitHub free or legacy plans
d. anyone who can view a project, regardless of access level
a. only users with admin access to a project
Overall explanation
The only users who can use the Insights feature for Projects are those with write or admin access to the specific project.
WRONG ANSWERS:
Being able to use the Insights feature does not have to do with the type of GitHub plan the user has, it just has to do with access levels to the project
People with just viewing access cannot use the Insights feature since they do not have write or admin access on the project
Although users with admin access can use Insights, it also includes users with write access
Which of the following is NOT a built-in metadata option to help build a richer view of item attributes?
a. Assignee
b. Labels
c. Milestone
d. Timestamp
d. Timestamp
Overall explanation
Although a user could add a timestamp field, it is not one of the built-in metadata that GitHub provides. A user would have to add it to their project manually if it is needed in the type of project they are creating
WRONG ANSWERS:
Milestones are one of the built-in metadata that GitHub provides. They track progress on groups of issues or pull requests in a repository
Labels are another built-in metadata that GitHub provides, they are used to classify issues, pull requests, and discussions
Assignees are also a built-in metadata that GitHub provides
As a project manager using GitHub, you notice that your team’s project board lacks clear categorization for issues and tasks, and you want to to enhance organization and communication. How can utilizing labels in GitHub Projects benefit your team in terms of project management?
a. labels allow you to customize the appearance of the project board, improving its visual appeal
b. labels enable real-time collaboration on code editing within the GitHub repository
c. labels provide a way to prioritize and categorize issues, making it easier to track and manage tasks on the project board
d. labels are primarily for assigning access permissions to team members based on their roles
c. labels provide a way to prioritize and categorize issues, making it easier to track and manage tasks on the project board
Overall explanation
Labels in GitHub Projects are used to prioritize and categorize issues, making it easier to track and manage tasks on the project board. This enhances organization and communication within the team.
WRONG ANSWERS:
Labels are not used for assigning access permissions. Access permissions are typically managed at the repository or organization level.
Real-time collaboration on code editing is not the primary purpose of labels in GitHub Projects. Labels are more focused on issue categorization.
Labels are not primarily for customizing the appearance of the project board but for categorizing and prioritizing issues.
What type of file is used to define a workflow in GitHub Actions?
a. JSON file
b. CSV file
c. Markdown file
d. Correct answer
e. YAML file
e. YAML file
Overall explanation
GitHub uses YAML because it is a commonly used, human-readable data serialization format. Its flexibility and many different use cases are why GitHub chose YAML.
WRONG ANSWERS:
Markdown is a lightweight markup language used for text formatting. While there are markdown files on GitHub, they are not used to define workflows. However, you can use them to document the functions of your workflow and YAML file.
GitHub Actions workflows are not defined using a CSV file because CSV files are used for data storage.
JSON files are used for scripting or temporary data storage.
You are participating in a GitHub discussion where comments have been made in response to a question. You’ve received a helpful response and want to highlight the comment to allow visitors to find the answer quickly. What action should you take?
a. lock the discussion so it remains the last answer of the discussion
b. create an issue and link the discussion
c. instruct users to use discussion insights to find the answer
d. mark the comment as the answer to the discussion
d. mark the comment as the answer to the discussion
Overall explanation
You can mark a comment in the discussion as an answer to the discussion if a discussion is within a category that accepts answers. When you mark a question as an answer, GitHub will highlight the comment and replies to the comment to help visitors quickly find the answer.
WRONG ANSWERS:
you don’t need to lock the discussion. Additional comments may still allow others to ask additional questions or provide additional insight or tips for others. You should simply mark the comment as the answer.
discussion insights will show data behind all of the discussions in the repo, not specific answers to questions. You should simply mark the comment as the answer.
you don’t need to create an issue and link the discussion. You should simply mark the comment as the answer.
What differentiates Projects from Projects Classic in terms of user interface customization options?
Correct answer
a. Projects provides more flexibility in customizing project boards and workflows
b. Both Projects and Projects Classic share the same user interface
c. Projects has a fixed and non-customizable user interface
d. Projects has a less customizable interface compared to Projects Classic
a. Projects provides more flexibility in customizing project boards and workflows
Overall explanation
Projects offers more customizable options for project boards and workflows compared to Projects Classic. Projects allows users to adjust the experience to their specific needs making it better for tracking progress and organizing issues and pull requests.
WRONG ANSWERS:
Projects actually have a more customizable interface than Projects Classic
Projects and Projects Classic do not share the same user interface. Projects Classic is simpler while Projects has more features and is more advanced
Projects do not have a fixed and non-customizable user interface. Projects have many customizable options to better organize the groups projects issues, pull requests, and draft issues
What can be determined based on the following CODEOWNERS file?
- *.tf @acme/infrastructure
- /docs/ @dani
a. changes to files in the docs folder need to be reviewed by the GitHub user dani for a pull-request
b. review assignments are assigned by placing this CODEOWNERS file in the owners folder within the repository
c. the GitHub user dani has code ownership for all individual commits made in the docs folder
d. changes to files with the tf extension need to be reviewed by the infrastructure user
a. changes to files in the docs folder need to be reviewed by the GitHub user dani for a pull-request
Changes to files in the docs folder need to be reviewed by the user dani. A CODEOWNERS file uses a pattern that follows most of the same rules used in gitignore files. The pattern is followed by one or more GitHub usernames or team names using the standard @username or @org/team-name format.
WRONG ANSWERS:
Teams can be specified as code owners. Teams should be identified in the format @org/team-name. Changes to files with the tf extension need to be reviewed by the infrastructure team within the acme organization.
To use a CODEOWNERS file, create a new file called CODEOWNERS in the .github/, root, or docs/ directory of the repository, in the branch where you’d like to add the code owners. If the CODEOWNERS file exists in other directories it will be ignored.
The CODEOWNERS file in a GitHub repository is used to specify individuals or teams responsible for code reviews in specific directories or for specific file types. It does not determine ownership of individual commits; rather, it influences the review process and notifies specified owners or teams when changes are made to the indicated files or directories.
Thomas has created a new repository in the GitHub UI and needs to add a new file. What is the correct way to achieve this?
a. Create a new branch for each new file and manually add the files in the GitHub web interface.
b. Use the git push command after adding the files to his local repository.
c. Click the “Add file” button on the repository’s GitHub page to Create a New File or Upload an Existing file to the repository.
d. Download the files to his local machine and copy them into the repository folder.
c. Click the “Add file” button on the repository’s GitHub page to Create a New File or Upload an Existing file to the repository.
Overall explanation
You can upload and commit an existing file to a repository on GitHub or by using the command line. If the repository contains files for an existing project, you can create a new branch, upload the files, and submit a pull request.
WRONG ANSWERS:
Downloading and copying files manually into the repository folder differs from the recommended way to add files, especially for version-controlled projects.
The git push command is used to push changes from a local repository to a remote repository. Still, it assumes that the files have already been added to the local repository using “git add.”
Creating a new branch and manually adding files in the GitHub web interface is not the standard method for adding files to a repository; it’s more suitable for creating branches or making changes to existing files.
Which features are commonly found in a user’s public GitHub user profile?
a. metadata, achievements, profile readme, repositories, pinned repositories, and stars
b. comment history, project forks, and file downloads
c. private repositories, project boards, and code snippets
d. wiki contributions, organization memberships, and follower count
a. metadata, achievements, profile readme, repositories, pinned repositories, and stars
Overall explanation
A user’s GitHub profile includes metadata (user information), achievements, profile readme, repositories, pinned repositories, and stars. These features provide a comprehensive overview of a user’s GitHub activity, contributions, and projects.
WRONG ANSWERS:
comment history, project forks, and file downloads are not typically featured in the user profile; they relate to specific repositories or project details
private repositories, project boards, and code snippets are aspects of GitHub but are not directly part of the user profile
wiki contributions, organization memberships, and follower count are relevant but are not primary features displayed in the user profile
Whenever you work in a GitHub codespace, what type of machine are you working on?
a. a dev container running on a virtual machine managed by GitHub
b. a local machine running GitHub Desktop
c. a virtual machine running on your local hardware
d. a virtual machine running in your own Microsoft Azure account
a. a dev container running on a virtual machine managed by GitHub
Overall explanation
Development containers, or dev containers, are Docker containers that are specifically configured to provide a fully featured development environment. Whenever you work in a codespace, you are using a dev container on a virtual machine.
WRONG ANSWERS:
Codespaces are not based on a dedicated machine physically connected to your computer. They are cloud-hosted, allowing for remote development.
Codespaces are cloud-based, and you are not working on a local machine running GitHub Desktop. Codespaces provide a remote development
environment accessible from your browser.
While Codespaces do run in Azure, they are managed by GitHub and don’t run in your own account
As a GitHub project manager, you are reaching the maximum limit of items in a project, and you need a way to manage the project’s content so there are no interruptions. What GitHub feature can you archive items as they are closed as completed or not planned?
a. configure your project’s built-in workflows to archive the desired items automatically
b. change the milestone of the impacted issues or pull requests to a later date
c. reopen the issues so the status is no longer completed or not planned
d. use filters to display only the items in the project view to stay below the maximum limit
a. configure your project’s built-in workflows to archive the desired items automatically
Overall explanation
You can configure your project’s built-in workflows to automatically archive items that match a filter. You can configure your project’s built-in workflows to automatically archive items. Archiving items will help you stay below the limit of 1,200 items in each project. The auto-archive workflow supports a subset of filters. You can use the following filters when configuring your workflow.
WRONG ANSWERS:
While filters would allow you to group items together, it wouldn’t remove them from the project, resulting in you hitting the maximum number of items in the project
changing the milestone wouldn’t help here, as it wouldn’t remove them from the project, resulting in you hitting the maximum number of items in the project
reopening the issues wouldn’t help because it wouldn’t remove them from the project, resulting in you hitting the maximum number of items in the project
As a developer, you want to programmatically manage a GitHub project without logging into the GitHub user interface. What options do you have to do this? (select two)
a. use the GitHub Wiki functionality to programmatically manage GitHub projects
b. use the GitHub CLI to create and manage issues and pull requests
c. download and install Git to manage existing issues
d. use the GraphQL API to manage the project
b. use the GitHub CLI to create and manage issues and pull requests
d. use the GraphQL API to manage the project
Overall explanation
GitHub CLI is a command-line tool that brings pull requests, issues, GitHub Actions, and other GitHub features to your terminal, so you can do all your work in one place.
The GitHub GraphQL API offers flexibility and the ability to define precisely the data you want to fetch.
WRONG ANSWERS:
Using Git commands directly in the terminal is primarily for version control tasks and does not provide direct access to GitHub project management features. GitHub CLI or API would be more suitable for project management tasks.
The GitHub Wiki functionality is primarily designed for creating and managing documentation within a repository. It is not a direct tool for programmatically managing GitHub projects. Developers would typically use the GitHub CLI, API, or GitHub Actions for such tasks.
When working with GitHub repositories, what is the purpose of cloning a repository to your local machine?
a. cloning is necessary only for creating backup copies of a repository and does not directly support collaborative development
b. cloning enables you to fetch only the latest changes and the main branch from GitHub.com, making it efficient for quick updates without downloading the entire repository.
c. cloning allows you to copy the entire repository from GitHub.com to your local machine or codespace
d. cloning allows you to create a new, entirely separate repository for personal use, providing isolation from the original project.
c. cloning allows you to copy the entire repository from GitHub.com to your local machine or codespace
Overall explanation
Cloning allows you to copy the entire repository from GitHub.com to your local machine or codespace, providing a full version history and enabling contributions to the project. This process facilitates collaboration by allowing contributors to work locally and make changes before pushing them to the remote repository.
WRONG ANSWERS:
Cloning is not meant to create entirely separate repositories. Instead, it is intended to replicate the existing project for collaborative development, ensuring contributors have a synchronized copy of the project.
Cloning does not fetch only the latest changes but pulls down a full copy of all repository data. It provides a comprehensive snapshot of the project’s current state, not just the latest updates.
Cloning is not necessary only for creating backups. Its primary purpose is to support collaborative development by providing a local copy of the repository for contributors to work on and contribute changes.
Organization owners can require two-factor authentication in their organization for all of the following except:
a. organization members
b. outside collaborators
c. billing managers
d. repository viewers
d. repository viewers
Overall explanation
Organization owners can require organization members, outside collaborators, and billing managers to enable two-factor authentication for their personal accounts, making it harder for malicious actors to access an organization’s repositories and settings. Repository viewers who have read-only access to repositories, are not subject to the organization-wide two-factor authentication requirement.
WRONG ANSWERS:
Organization owners can require two-factor authentication for all members of the organization to enhance security.
Organization owners can require two-factor authentication for outside collaborators who are users external to the organization but have access to specific repositories.
Organization owners can require two-factor authentication for billing managers within an organization.
Bryan is a content creator and wants to offer students hands-on experience using codespaces. How can he share codespace links directly to a browser?
a. share a deep link in the course materials that, when clicked, opens a pre-configured Codespace in the browser
b. provide instructions for installing the GitHub CLI and using specific commands to initiate Codespaces creation
c. ask students to clone the repository and set up Codespaces individually based on their preferences
d. instruct students to manually create Codespaces by navigating to the GitHub repository’s main page
a. share a deep link in the course materials that, when clicked, opens a pre-configured Codespace in the browser
Overall explanation
You can make it easy for people to work on your repository in a codespace by providing a link to the codespace creation page. You can add a link to take people straight to a page for creating a codespace, with your choice of options preconfigured. Alternatively you can link to the “Resume codespace” page.
WRONG ANSWERS:
Instructing students to manually create Codespaces by navigating to the GitHub repository’s main page is not the most efficient way to provide hands-on experience.
Asking students to clone the repository and set up Codespaces individually introduces unnecessary complexity and manual steps.
Providing instructions for installing the GitHub CLI and using specific commands adds complexity and might be challenging for students, especially beginners.
What is the primary characteristic of open-source software?
a. developed by a single company
b. free and accessible source code
c. exclusive for commercial use
d. closed and proprietary code
b. free and accessible source code
Overall explanation
Open-source software is characterized by its freely available source code that can be viewed, modified, and redistributed by anyone. The openness of the source code allows collaboration and community-driven development.
****
WRONG ANSWERS:
Open-source software is typically developed collaboratively by a community of contributors rather than being owned or controlled by a single company.
Open-source software is the opposite of closed and proprietary software. Open-source code is open for inspection, modification, and distribution, while proprietary code is closed and not freely available.
Open-source software can be used for both commercial and non-commercial purposes. It is not exclusive to any specific type of usage and encourages a wide range of applications and uses.
Which of the following best describes the roadmap layout in GitHub projects?
a. a layout with customizable columns with your issues, pull requests, and draft issues
b. a configurable timespan to track your issues, pull requests, and draft issues on a timeline
c. a layout that organizes issues, pull requests, and draft issues into a hierarchical tree structure
d. a powerful and adaptable spreadsheet with your issues, pull requests, and draft issues
b. a configurable timespan to track your issues, pull requests, and draft issues on a timeline
Overall explanation
The roadmap layout provides a high-level visualization of your project across a configurable timespan. It allows you to drag items to affect their start and target dates or selected iterations. Roadmaps enables the users to customize the data and iteration fields to position the issues, pull requests, and draft issues on a timeline.
WRONG ANSWERS:
The table layout option is a powerful and adjustable spreadsheet with issues, pull requests, and draft issues.
The layout that utilizes customizable columns for a project issues, pull requests, and draft issues is the board layout
GitHub Projects does not have a layout option to organize issues, pull requests, and draft issues into a hierarchical tree structure
Why might a developer use a branch for development in Git or GitHub?
a. to isolate and work on a set of changes independently from the main project
b. to archive and store old versions of project files
c. to permanently separate code contributions made by different developers
d. to create a duplicate copy of the entire repository
a. to isolate and work on a set of changes independently from the main project
Overall explanation
Developers use branches to create an isolated environment for specific tasks, such as developing new features or fixing bugs. By doing so, they can work independently without affecting the main codebase. This isolation allows for focused development, testing, and collaboration, and the changes can be later merged back into the main branch or another target branch.
WRONG ANSWERS:
creating a duplicate copy of the entire repository is unnecessary and not the primary purpose of using branches for development
branches are not intended to separate code contributions permanently; they are temporary environments for isolated development tasks
archiving old versions of project files is not the primary purpose of using branches; their main role is to facilitate concurrent and isolated development
What are the primary differences between GitHub Desktop and GitHub.com?
a. GitHub Desktop is a version control system
b. Github.com is a graphical user interface for Git
c. GitHub Desktop is exclusively used for online code editing with GitHub services
d. Github.com is focused on both online and offline development.
e. GitHub Desktop is a free, open-source application that helps you to work with files hosted on GitHub or other Git hosting services
f. GitHub.com is a web-based platform for hosting, collaboration, and project management
g. GitHub Desktop is a command-line interface for Git
h. Github.com is a web-based platform for hosting repositories
e. GitHub Desktop is a free, open-source application that helps you to work with files hosted on GitHub or other Git hosting services
Overall explanation
GitHub Desktop is a desktop application for managing Git repositories locally, while github.com is a web-based platform for hosting, collaboration, and project management.
WRONG ANSWERS:
GitHub Desktop is not a command-line interface for Git, and github.com is a web-based platform, not a command-line tool
GitHub Desktop is not a version control system on its own; it is a desktop client for working with Git
GitHub Desktop supports both online and offline development
What type of files and content can be included in a template repository?
a. any files or content that are relevant to the project
b. only README files
c. files cannot be included in a template repository
d. only source code files
a. any files or content that are relevant to the project
Overall explanation
While creating a template repository, a user can include any files or content that are relevant to the project that they are creating. This is beneficial and creates a more simple creation process for the user than creating a brand new repository.
WRONG ANSWERS:
Source code files can be included in a template repository, but they are not the only files or content that can be included
README files can be included in a template repository, but they are not the only field or content that can be included
Template repositories can include the same directory structure, branches, and files
What are the different repository visibility options for GitHub Enterprise?
a. private, public, and internal
b. personal, public, and internal
c. private, public, and secure
d. personal, public, and secure
a. private, public, and internal
Overall explanation
Within GitHub Enterprise you can restrict who has access to a repository by choosing a repository’s visibility: public, internal, or private.
WRONG ANSWERS:
There is not a “personal” visibility setting offered by GitHub.
There is not a “secure” visibility setting offered by GitHub.
There is not a “personal” or “secure” visibility setting offered by GitHub.
Which locations can you define the actions used in your workflow in GitHub Actions? (select three)
Your selection is correct
a. a published Docker container image on Docker Hub
b. the same repository as your workflow file
c. actions can only be defined in private repositories
d. any public repository
a. a published Docker container image on Docker Hub
b. the same repository as your workflow file
d. any public repository
Overall explanation
A reusable workflow can be used by another workflow if any of the following is true:
Both workflows are in the same repository.
The called workflow is stored in a public repository, and your organization allows you to use public reusable workflows.
The called workflow is stored in a private repository and the settings for that repository allow it to be accessed.
What feature can developers take advantage of by using the GitHub Marketplace?
a. a single place to connect, follow, and chat with other members of the GitHub community
b. the ability to publish and share their GitHub Actions and Apps
c. a storefront for anyone to sell their GitHub Apps to others
d. a single place to manage their GitHub subscription, purchase additional GitHub Actions storage and minutes and access GitHub Apps
b. the ability to publish and share their GitHub Actions and Apps
Overall explanation
The GitHub Marketplace allows developers to share GitHub Actions and Apps with the GitHub community.
WRONG ANSWERS:
The primary intention of the GitHub Marketplace is to list free and paid tools for developers to use. It is not a single place to connect and follow members of the GitHub community.
Anyone can share their apps with other users for free on GitHub Marketplace, but only apps owned by organizations can sell their apps.
GitHub Marketplace offers developers two types of tools: GitHub Actions and Apps. Managing GitHub subscriptions, GitHub Actions storage, and minutes are not provided within the GitHub Marketplace.