#include <bits/stdc++.h>
using namespace std;
mt19937 rng(229);
struct CartesianTree {
  struct Node {
    int val;
    int prior;
    int sz;
    int l;
    int r;
    Node(int x) {
      val = x;
      prior = rng();
      sz = 1;
      l = -1;
      r = -1;
    }
  };
  int root;
  vector<Node> t;
  int new_node(int x) {
    t.push_back(Node(x));
    return (int)t.size() - 1;
  }
  int get_sz(int v) {
    if (v == -1) {
      return 0;
    } else {
      return t[v].sz;
    }
  }
  void pull(int v) { t[v].sz = get_sz(t[v].l) + 1 + get_sz(t[v].r); }
  int merge(int a, int b) {
    if (a == -1) {
      return b;
    } else if (b == -1) {
      return a;
    } else if (t[a].prior < t[b].prior) {
      t[a].r = merge(t[a].r, b);
      pull(a);
      return a;
    } else {
      t[b].l = merge(a, t[b].l);
      pull(b);
      return b;
    }
  }
  pair<int, int> split(int v, int k) {
    if (v == -1) {
      return {-1, -1};
    } else {
      int ls = get_sz(t[v].l);
      if (k - ls - 1 >= 0) {
        auto p = split(t[v].r, k - ls - 1);
        t[v].r = p.first;
        pull(v);
        return {v, p.second};
      } else {
        auto p = split(t[v].l, k);
        t[v].l = p.second;
        pull(v);
        return {p.first, v};
      }
    }
  }
  bool check_val(int pos, int val) {
    int l, mid, r;
    tie(mid, r) = split(root, pos + 1);
    tie(l, mid) = split(mid, pos);
    if (t[mid].val == -1) {
      t[mid].val = val;
    }
    int res = t[mid].val;
    root = merge(l, merge(mid, r));
    return res == val;
  }
  int get_val(int pos) {
    int l, mid, r;
    tie(mid, r) = split(root, pos + 1);
    tie(l, mid) = split(mid, pos);
    int res = t[mid].val;
    root = merge(l, merge(mid, r));
    return res;
  }
  void move_front(int pos) {
    int l, mid, r;
    tie(mid, r) = split(root, pos + 1);
    tie(l, mid) = split(mid, pos);
    root = merge(mid, merge(l, r));
  }
  CartesianTree(int n) {
    root = -1;
    for (int i = 0; i < n; i++) {
      root = merge(root, new_node(i));
    }
  }
};
signed main() {
  ios_base::sync_with_stdio(false);
  cin.tie(0);
  int n, q;
  cin >> n >> q;
  CartesianTree cur(n);
  vector<int> ans(n, -1);
  while (q--) {
    int x, y;
    cin >> x >> y;
    x--;
    y--;
    int who = cur.get_val(y);
    if (ans[who] != -1 && ans[who] != x) {
      cout << -1 << endl;
      exit(0);
    }
    ans[who] = x;
    cur.move_front(y);
  }
  vector<int> fr(n, 1);
  for (int i = 0; i < n; i++) {
    if (ans[i] != -1) {
      fr[ans[i]]--;
      if (fr[ans[i]] < 0) {
        cout << -1 << endl;
        exit(0);
      }
    }
  }
  int pnt = 0;
  for (int i = 0; i < n; i++) {
    if (ans[i] == -1) {
      while (!fr[pnt]) {
        pnt++;
      }
      ans[i] = pnt;
      pnt++;
    }
  }
  for (auto t : ans) {
    cout << t + 1 << ' ';
  }
  cout << endl;
}
