Skip to content

Commit

Permalink
Merge pull request #22457 from def-/pr-services-ignore
Browse files Browse the repository at this point in the history
git: Ignore services.log
  • Loading branch information
def- authored Oct 18, 2023
2 parents 283bdac + 7c8d344 commit a7488b1
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 20 deletions.
34 changes: 18 additions & 16 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -9,36 +9,38 @@
#
# https://github.com/github/gitignore/tree/master/Global

target
target-ra
target-xcompile
miri-target
/target
/target-ra
/target-xcompile
/miri-target
.mtrlz.log
**/*.rs.bk
*.rs.bk
mzdata
__pycache__
.mypy_cache
venv
node_modules
coverage
test/feature-benchmark/tmp/*.td
test/zippy/tmp/*.td
test/**/tmp_*.toml
/coverage
/test/feature-benchmark/tmp/*.td
/test/zippy/tmp/*.td
/test/**/tmp_*.toml
junit_*.xml
parallel-workload-queries.log
perf.data*
**/*.rej
**/*.orig
**/*.profraw
**/*.profdata
**/*.debug
scratch
*.rej
*.orig
*.profraw
*.profdata
*.debug
/scratch
services.log
*.swp

# This is un-orthodox, but adding it to the repo would "tie" it to each user's
# local version of nixpkgs. This way, we can all use the flake and have a
# flake.lock that works well with the rest of the package versions on our
# system.
**/flake.lock
flake.lock

/misc/python/materialize/build/
/misc/python/materialize/*.egg-info/
Expand Down
8 changes: 4 additions & 4 deletions misc/python/materialize/cli/scratch/create.py
Original file line number Diff line number Diff line change
Expand Up @@ -122,16 +122,16 @@ def run(args: argparse.Namespace) -> None:
extra_tags["LaunchedBy"] = whoami()

if args.machine:
with open(MZ_ROOT / "misc" / "scratch" / "{}.json".format(args.machine)) as f:
with open(MZ_ROOT / "misc" / "scratch" / f"{args.machine}.json") as f:

print("Reading machine configs from {}".format(f.name))
print(f"Reading machine configs from {f.name}")
descs = [MachineDesc.parse_obj(obj) for obj in multi_json(f.read())]
else:
print("Reading machine configs from stdin...")
descs = [MachineDesc.parse_obj(obj) for obj in multi_json(sys.stdin.read())]

if args.ssh and len(descs) != 1:
raise RuntimeError("Cannot use `--ssh` with {} instances".format(len(descs)))
raise RuntimeError(f"Cannot use `--ssh` with {len(descs)} instances")

if args.max_age_days <= 0:
raise RuntimeError(f"max_age_days must be positive, got {args.max_age_days}")
Expand All @@ -152,5 +152,5 @@ def run(args: argparse.Namespace) -> None:
print_instances(instances, args.output_format)

if args.ssh:
print("ssh-ing into: {}".format(instances[0].instance_id))
print(f"ssh-ing into: {instances[0].instance_id}")
mssh(instances[0], "")
Empty file removed services.log
Empty file.

0 comments on commit a7488b1

Please sign in to comment.