#include <bits/stdc++.h>
using namespace std;
class Splay {
 public:
  Splay() {
    root = nil = new Node();
    nil->ch[0] = nil->ch[1] = nil;
    nil->key = -1;
    nil->sz = 0;
    tot = top = idx = 0;
  }
  ~Splay() {}
  void init(const int *l, const int *r) {
    tot = top = 0;
    makeNode(root, 1000000000, nil);
    makeNode((root->ch[1]), 1000000000, root);
    makeTree((root->ch[1]->ch[0]), l, 0, r - l - 1, (root->ch[1]));
    pushUp((root->ch[1]));
    pushUp(root);
  }
  void clear() {
    root = nil;
    tot = top = 0;
  }
  void insert(int k, int val) {
    select(k, nil);
    select(k + 1, root);
    makeNode((root->ch[1]->ch[0]), val, (root->ch[1]));
    pushUp((root->ch[1]));
    pushUp(root);
  }
  void erase(int k) {
    select(k - 1, nil);
    select(k + 1, root);
    stk[++top] = (root->ch[1]->ch[0]);
    (root->ch[1]->ch[0]) = nil;
    pushUp((root->ch[1]));
    pushUp(root);
  }
  bool empty() { return root == nil; }
  int size() { return root->sz; }
  int select(int k) {
    select(k, nil);
    return root->key;
  }
  int getItems(int *a) {
    idx = 0;
    getItems(a, root);
    return root->sz;
  }

 private:
  struct Node {
    int key, sz;
    Node *ch[2], *pre;
  } v[1000100], *stk[1000100], *root, *nil;
  int tot, top, idx;
  void pushUp(Node *x) { x->sz = x->ch[0]->sz + x->ch[1]->sz + 1; }
  void pushDown(Node *x) {}
  void rotate(Node *x, int d) {
    Node *y = x->pre;
    pushDown(y);
    pushDown(x);
    if (y->ch[d ^ 1] = x->ch[d]) x->ch[d]->pre = y;
    if (x->pre = y->pre) y->pre->ch[y->pre->ch[1] == y] = x;
    x->ch[d] = y;
    y->pre = x;
    pushUp(y);
  }
  void splay(Node *x, const Node *p) {
    Node *y;
    int d;
    for (pushDown(x); (y = x->pre) != p;) {
      if (y->pre == p)
        rotate(x, y->ch[0] == x);
      else {
        d = (y->pre->ch[0] == y);
        rotate(y->ch[d] == x ? x : y, d ^ (y->ch[d] == x));
        rotate(x, d);
      }
    }
    pushUp(x);
    if (p == nil) root = x;
  }
  void select(int k, const Node *p) {
    Node *x = root;
    int d;
    for (pushDown(x); x->ch[0]->sz != k; pushDown(x = x->ch[d])) {
      if (d = (x->ch[0]->sz < k)) k -= x->ch[0]->sz + 1;
    }
    splay(x, p);
  }
  void makeNode(Node *&x, int k, Node *p) {
    x = top ? stk[top--] : v + tot++;
    x->key = k;
    x->sz = 1;
    x->ch[0] = x->ch[1] = nil;
    x->pre = p;
  }
  void makeTree(Node *&x, const int *a, int l, int r, Node *p) {
    int mid = (l + r) >> 1;
    makeNode(x, a[mid], p);
    if (l < mid) makeTree(x->ch[0], a, l, mid - 1, x);
    if (mid < r) makeTree(x->ch[1], a, mid + 1, r, x);
    pushUp(x);
  }
  void getItems(int *a, Node *x) {
    if (x == nil) return;
    pushDown(x);
    getItems(a, x->ch[0]);
    a[idx++] = x->key;
    getItems(a, x->ch[1]);
  }
} spt;
int cur[1000100], pos[1000100], ans[1000100], x[1000100], y[1000100],
    num[1000100];
bool solve(int n, int m) {
  int u, cnt = 0, i, j;
  memset(ans, -1, sizeof(ans));
  memset(pos, -1, sizeof(pos));
  for (i = 1; i <= n; ++i) num[i] = i;
  spt.clear();
  spt.init(num + 1, num + n + 1);
  for (i = 0; i < m; ++i) {
    u = spt.select(y[i]);
    if (~pos[x[i]] && pos[x[i]] != u) return false;
    if (~ans[u] && ans[u] != x[i]) return false;
    pos[x[i]] = u;
    ans[u] = x[i];
    spt.erase(y[i]);
    spt.insert(0, u);
  }
  for (i = 1; i <= n; ++i) {
    if (pos[i] == -1)
      num[cnt++] = i;
    else
      ans[pos[i]] = i;
  }
  for (i = 1, j = 0; i <= n; ++i) {
    if (ans[i] == -1) ans[i] = num[j++];
  }
  return true;
}
int main() {
  int n, m, i;
  while (~scanf("%d%d", &n, &m)) {
    for (i = 0; i < m; ++i) scanf("%d%d", &x[i], &y[i]);
    if (!solve(n, m))
      printf("-1\n");
    else {
      for (i = 1; i <= n; ++i) printf("%d%c", ans[i], i < n ? ' ' : '\n');
    }
  }
  return 0;
}
