Skip to content

Commit

Permalink
update infrastructure
Browse files Browse the repository at this point in the history
removed travis because it does not work anymore, looking forward for
some other CI solution
  • Loading branch information
corpix committed Jun 25, 2022
1 parent 521e8af commit 352b3d4
Show file tree
Hide file tree
Showing 12 changed files with 100 additions and 31 deletions.
16 changes: 16 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
root = true

[*]
charset = utf-8
end_of_line = lf
indent_style = space
indent_size = 2
insert_final_newline = true
trim_trailing_whitespace = true

[{*.go,go.mod,go.sum}]
indent_style = tab

[makefile]
indent_style = tab
indent_size = 2
11 changes: 0 additions & 11 deletions .go-makefile.json

This file was deleted.

11 changes: 0 additions & 11 deletions .travis.yml

This file was deleted.

6 changes: 0 additions & 6 deletions glide.lock

This file was deleted.

3 changes: 0 additions & 3 deletions glide.yaml

This file was deleted.

7 changes: 7 additions & 0 deletions go.mod
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
module github.com/icrowley/fake

go 1.17

require github.com/corpix/uarand v0.0.0-20170723150923-031be390f409

require github.com/stretchr/testify v1.7.5 // indirect
16 changes: 16 additions & 0 deletions go.sum
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
github.com/corpix/uarand v0.0.0-20170723150923-031be390f409 h1:9A+mfQmwzZ6KwUXPc8nHxFtKgn9VIvO3gXAOspIcE3s=
github.com/corpix/uarand v0.0.0-20170723150923-031be390f409/go.mod h1:JSm890tOkDN+M1jqN8pUGDKnzJrsVbJwSMHBY4zwz7M=
github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c=
github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM=
github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
github.com/stretchr/objx v0.4.0/go.mod h1:YvHI0jy2hoMjB+UWwv71VJQ9isScKT/TqJzVSSt89Yw=
github.com/stretchr/testify v1.7.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg=
github.com/stretchr/testify v1.7.5 h1:s5PTfem8p8EbKQOctVV53k6jCJt3UX4IEJzwh+C324Q=
github.com/stretchr/testify v1.7.5/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU=
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=
gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA=
gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=
File renamed without changes.
File renamed without changes.
23 changes: 23 additions & 0 deletions nix-cage.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
{
"mounts": {
"rw": [
".", "~/.emacs.d",
["./.cache", "~/.cache", "d"],
["./.config", "~/.config", "d"],
["./.local", "~/.local", "d"],
["$SSH_AUTH_SOCK", "$SSH_AUTH_SOCK"],
"/run"
],
"ro": [
"~/.ssh",
"~/.gitconfig",
"/"
],
"dev": ["/dev"],
"tmpfs": [
"/tmp",
"/home",
"~"
]
}
}
File renamed without changes.
38 changes: 38 additions & 0 deletions shell.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
let
inherit (pkgs)
writeScript
stdenv
;

nixpkgs = <nixpkgs>;
config = {};
pkgs = import nixpkgs { inherit config; };

shellWrapper = writeScript "shell-wrapper" ''
#! ${stdenv.shell}
set -e
exec -a shell ${pkgs.fish}/bin/fish --login --interactive "$@"
'';
in stdenv.mkDerivation rec {
name = "nix-shell";
buildInputs = with pkgs; [
glibcLocales bashInteractive man
nix cacert curl utillinux coreutils
git jq yq-go tmux findutils gnumake

go gopls golangci-lint
];
shellHook = ''
export root=$(pwd)
export LANG="en_US.UTF-8"
export NIX_PATH="nixpkgs=${nixpkgs}"
if [ ! -z "$PS1" ]
then
export SHELL="${shellWrapper}"
exec "$SHELL"
fi
'';
}

0 comments on commit 352b3d4

Please sign in to comment.